whelpton Posted August 10, 2009 Share Posted August 10, 2009 Hello everyone. I completely forgot the way to process information after the url. For example test.com/index.php?INFO I cant remember how to use the INFO section of the url Quote Link to comment https://forums.phpfreaks.com/topic/169528-solved-completely-forgotton-the-function/ Share on other sites More sharing options...
jonsjava Posted August 10, 2009 Share Posted August 10, 2009 test.com/index.php?INFO=this_info to get the data, do this: <?php if (isset($_GET['info'])){ $info = $_GET['info']; } else{ $info = "not set"; } print $info; ?> Quote Link to comment https://forums.phpfreaks.com/topic/169528-solved-completely-forgotton-the-function/#findComment-894453 Share on other sites More sharing options...
halfman Posted August 10, 2009 Share Posted August 10, 2009 Hello everyone. I completely forgot the way to process information after the url. For example test.com/index.php?INFO I cant remember how to use the INFO section of the url No worries mate, it is the query string Example http://www.domainname.com/index.php?variableName=variableValue In PHP it is a $_GET Global Array. you can echo that by <?php echo $_GET['variableName']; ?> also you can use $_REQUEST['variableName']; Hope this help. Google php query string you will get some good documents too. Quote Link to comment https://forums.phpfreaks.com/topic/169528-solved-completely-forgotton-the-function/#findComment-894459 Share on other sites More sharing options...
whelpton Posted August 10, 2009 Author Share Posted August 10, 2009 Thanks a bunch guys! Quote Link to comment https://forums.phpfreaks.com/topic/169528-solved-completely-forgotton-the-function/#findComment-894475 Share on other sites More sharing options...
nankoweap Posted August 10, 2009 Share Posted August 10, 2009 it's important to note that if you're processing a form that has been defined with method="post", these values are only accessible via _POST and _REQUEST. jason Quote Link to comment https://forums.phpfreaks.com/topic/169528-solved-completely-forgotton-the-function/#findComment-894477 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.