vishak Posted June 14, 2010 Report Posted June 14, 2010 Hi... I've just started learning Ajax and my question is : I am passing these values in this url , http://localhost/test/check.php?sem=s1&s2&branch=cse the value of sem is actually s1&s2, but since & is the delimiter here I'm not able to receive the full value of sem Should i escape the & character?(if so, how?) Or is there any other way to overcome this? Quote
falkencreative Posted June 14, 2010 Report Posted June 14, 2010 Rather than using "&" try using "%26" http://community.contractwebdevelopment.com/url-escape-characters Quote
BeeDev Posted June 15, 2010 Report Posted June 15, 2010 Just to add, if you're using server-side languages like PHP or ASP u can do them automatically: PHP: http://localhost/test/check.php?sem=<?php echo urlencode('s1&s2'); ?>&branch=cse ASP: http://localhost/test/check.php?sem=<%=Server.URLEncode("s1&s2")%>&branch=cse Quote
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.
Note: Your post will require moderator approval before it will be visible.