visitor (0 QPoints)
  • FR
  • EN
  • NL
  • DE
  • ES
315 experts, 1193 registered users, 1659 questions already answered
European Experts Exchange, the very best site for high-quality IT solutions

New Improved Search!

 


05/10/2011 1h30 : Steve Jobs is dead, the father of Apple ][ is gone, we are all orphaned.

Languages :: PHP :: How to send '&' as a parmeter value?


By: PHP newbee U.S.A.  Date: 15/03/2003 00:00:00  English  Points: 125 Status: Answered
Quality : Excellent
I need to send values like var1=w&c but I get an error when I try to do this using the get method... What can i do?
By: VGR Date: 15/03/2003 07:36:00 English  Type : Answer
urlencode() the parameters line (full url if you want)before sending, urldecode after receiving

or I guess & could be escaped && or \& (I don't know, never had this problem and I'm too lazy to check the PHP dox ;-)
By: sumotimor Date: 15/03/2003 07:37:00 English  Type : Comment
Pass %26 instead of &
By: TheFalklands Date: 15/03/2003 08:10:00 English  Type : Comment
VGR is right.
You URLENCODE the values and in the next page you get the correct values w&c.
By: VGR Date: 15/03/2003 08:31:00 English  Type : Comment
I mean, %26 is a good solution, but urlendode/decode is good practice and is more general : it solves a lot of problems
By: sumotimor Date: 15/03/2003 10:24:00 English  Type : Comment
Agreed.

Do register to be able to answer

EContact
browser fav
page generated in 77.051160 milliseconds

Why Google AdSense ads ?

compteur
 Ranking-Hits PageRank for this page