Irvin Amoraal Posted February 4, 2010 Share Posted February 4, 2010 I have recently moved the site to a server running php v.5.2.6. I used to use: switch ($t) to test a url value, but that doesn't work on the new server. So i added the following code: $t = $Get['t']; also tried $t=$_Request['t']; but neither get the url value [url.com?t=about]. No error messages. Any ideas what I am doing wrong? Link to comment https://forums.phpfreaks.com/topic/190952-cant-_get-url-var/ Share on other sites More sharing options...
KevinM1 Posted February 4, 2010 Share Posted February 4, 2010 The superglobal arrays require you to write them correctly: $_GET['index'] $_POST['index'] $_REQUEST['index'] Where index is the name of the value you're trying to obtain. In your case: $_GET['t'] If that doesn't fix the problem, share more code. Link to comment https://forums.phpfreaks.com/topic/190952-cant-_get-url-var/#findComment-1006936 Share on other sites More sharing options...
Irvin Amoraal Posted February 5, 2010 Author Share Posted February 5, 2010 Duh! Thanks a bunch. I can't believe I didn't see that. Link to comment https://forums.phpfreaks.com/topic/190952-cant-_get-url-var/#findComment-1007254 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.