Welcome Guest, Not a member yet? Register   Sign In
Special chars in url
#1

[eluser]trumnation[/eluser]
hi, I am trying to send a string to my controller via the url. Before I send it, I encode it to remove special chars, etc. however, the resulting string is full of % signs.

I know % is included in the permitted chars in the config file, but I still am getting the "The URI you submitted has disallowed characters." error. Is there something I am missing here?

Here is an example url:

/mycontroller/submitstr/This+is+a+new+Post+can't+hello!/

Thanks!
#2

[eluser]MexiTek[/eluser]
Could it be the ' in that URL? Even if it gets converted to % 27 ? I am not an expert on url encoding, but if % 27 gets translated into an ' before checking the allowed chars it might throw your error.
#3

[eluser]WanWizard[/eluser]
Apache decodes the URL before it gets passed on, PHP never sees the '...
#4

[eluser]trumnation[/eluser]
ah sorry, I didn't look at the post after I submitted it.. seems the forum decoded that string back into + ' and ! after I submitted it. Yeah my problem is that codeigniter is somehow seeing that string with the %'s in it and not liking it. Should I be using a different approach or something?




Theme © iAndrew 2016 - Forum software by © MyBB