csckid Posted July 10, 2010 Share Posted July 10, 2010 after the following input I expected the "Ba & t" to be printed but only "Ba" was printed. How do I modify the code so that "Ba & t" is printed. http://localhost/test.php?c=Ba & t Thanks <?php require("phpfunc.fns"); sqlconnect(); $name=$_GET['c']; echo $name; ?> Link to comment https://forums.phpfreaks.com/topic/207340-string-in-get-method/ Share on other sites More sharing options...
jskywalker Posted July 10, 2010 Share Posted July 10, 2010 go to : http://localhost/test.php?c=Ba%20%26%20t and read about urlencode: http://nl2.php.net/manual/en/function.urlencode.php Link to comment https://forums.phpfreaks.com/topic/207340-string-in-get-method/#findComment-1084026 Share on other sites More sharing options...
csckid Posted July 10, 2010 Author Share Posted July 10, 2010 Thanks Link to comment https://forums.phpfreaks.com/topic/207340-string-in-get-method/#findComment-1084034 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.