justinh Posted December 29, 2008 Share Posted December 29, 2008 Hey everyone, I'm using XAMPP to host my files on localhost, everything is going good except $_GET isn't working. Is there a setting I need to change? Link to comment https://forums.phpfreaks.com/topic/138767-_get/ Share on other sites More sharing options...
rhodesa Posted December 29, 2008 Share Posted December 29, 2008 nope...shouldn't be. what "isn't working" about it? can you post a code example and what it is outputting that is unexpected? Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725565 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 everything is going good except $_GET isn't working. What is happening? Could you post some code? Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725567 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 <?php $testingget = $get['testing']; echo $testingget; ?> then when i go to http://localhost/testing.php?testing=doesthiswork it brings up a blank page Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725571 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 ugh nvm found the error.. should be $_GET['testing'] Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725573 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 Your syntax is wrong!!!!! $testingget = $_GET['testing']; Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725574 Share on other sites More sharing options...
rhodesa Posted December 29, 2008 Share Posted December 29, 2008 ugh nevermind found the error.. should be $_GET['testing'] i hate when that happens Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725575 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 Ok new code.. <?php $testingget = $_GET['testing']; echo $testingget; ?> still doesn't work Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725576 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 What's the URI? Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725577 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 http://localhost/testing.php?testing=doesthiswork Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725579 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 I just tested it on my server and it works. Are you sure you're editing your localhost file? Other than that I'm not sure, you don't have to turn anything on to have GET to work. Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725585 Share on other sites More sharing options...
rhodesa Posted December 29, 2008 Share Posted December 29, 2008 I just tested it on my server and it works. Are you sure you're editing your localhost file? Other than that I'm not sure, you don't have to turn anything on to have GET to work. yeah...works for me too. make sure you are editing the right file (and saving it) Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725586 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 Lol, forgot to save it.. i feel dumb. thanks everythings good now Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725589 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 Lol, forgot to save it.. i feel dumb. thanks everythings good now Hehe. Man there have been some pretty bad mistakes today. I may have to use this one as a signature... Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725591 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 i deserve it Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725592 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 This is my first time using localhost to host my php/mysql.. ussually i have to save it and ftp it to my webhosting, maybe that's the reason I forgot to save... Yeah that's it! Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725593 Share on other sites More sharing options...
rhodesa Posted December 29, 2008 Share Posted December 29, 2008 do we have a Wall-Of-Shame sticky in Miscellaneous? I didn't see one...maybe one should be started? Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725594 Share on other sites More sharing options...
justinh Posted December 29, 2008 Author Share Posted December 29, 2008 done. Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725599 Share on other sites More sharing options...
Maq Posted December 29, 2008 Share Posted December 29, 2008 do we have a Wall-Of-Shame sticky in Miscellaneous? I didn't see one...maybe one should be started? I agree! I could probably fill the first page with the mistakes and comments I've seen... Link to comment https://forums.phpfreaks.com/topic/138767-_get/#findComment-725607 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.