|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Be the architects of evolution and help create the mobile internet future. It’s your move---enter to win here! |
|
#1
|
|||
|
|||
|
http get vars and spaces
is there an easy why to handle spaces in get var strings?
like blah/script.php?name=this has spaces what is the best way to deal with this, I looked at html special chars but that looks like the & to $amp etc. What shopuld I use presumably to make the spaces %20, I could manually do this, I think the reason why it is not processing it like it does on a normal web page is that I am including the file. Thanks |
|
#2
|
|||
|
|||
|
RE: http get vars and spaces
Use urlencode() and then urldecode() to get it back....
|
|
#3
|
|||
|
|||
|
RE: http get vars and spaces
That's the one!!!!
Thanks you |
|
#4
|
|||
|
|||
|
RE: http get vars and spaces
works perfectly, don't even have to mess with them to convert them back, it does it itself!
Thanks for the pointer, I still have lots to learn. Thanks again |
|
#5
|
|||
|
|||
|
RE: http get vars and spaces
justo to note: beside the "%20" encoding of space, u can use "+" to encode space, ie if u write url by hand (and don't generate it from php code):
http://example.com/script.php??query=this+doesnt++or+does+it |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PHP Coding > http get vars and spaces |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|
|
|