nicob Posted May 3, 2009 Share Posted May 3, 2009 I tried to get the id info from http://www.domain.com/profile.php?id=v-&-cat but I only see the 'v-' The codes I tried <?= htmlentities($_GET['id']) ?> and <?php echo $_GET['id'] ?> Is this normal? And if so, how to fix this? thx! Quote Link to comment Share on other sites More sharing options...
nankoweap Posted May 3, 2009 Share Posted May 3, 2009 it's normal. an ampersand is used to separate one parameter/value pair from another. i'm pretty sure you can encode the value, though, and allow it to pass through. Quote Link to comment Share on other sites More sharing options...
Ken2k7 Posted May 3, 2009 Share Posted May 3, 2009 Why do you have that in the parameter anyways? Quote Link to comment Share on other sites More sharing options...
nicob Posted May 3, 2009 Author Share Posted May 3, 2009 Thank you. @Ken2k7 Some people like to use strange characters in their 'names'. It works ok in the browser, except this problem. Quote Link to comment Share on other sites More sharing options...
Ken2k7 Posted May 3, 2009 Share Posted May 3, 2009 You can urlencode() the output of the string and then urldecode(). Quote Link to comment Share on other sites More sharing options...
nicob Posted May 3, 2009 Author Share Posted May 3, 2009 Thanks Ken! Quote Link to comment 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.