Troubles with query strings |
[eluser]Zeff[/eluser]
Hi all, I'm trying to redirect to another controller method and I'm giving the reffering url as an url encoded parameter: eg: /login/index/?ref=http:/2Fwww.myserver.com/index.php/administration/overview/secret But on http://www.myserver.com/index.php/login/...iew/secret I'm getting a 404... I also tried to get it as extra segment with index($ref){} method in the login controller, but it gives also a 404. BTW: Query string are enabled in config! Help please... Thanks!
[eluser]jrtashjian[/eluser]
Use an ampersand '&' instead of a question mark '?'. Your URL should look like this: http://www.myserver.com/index.php/login/...iew/secret
[eluser]Zeff[/eluser]
Normally query strings are started with a question mark? e.g. program?query_string&other;_q_string But I tried your solution but it doesn't help... Thanks anyway.
[eluser]Dennis Rasmussen[/eluser]
[quote author="Zeff" date="1286552132"]Normally query strings are started with a question mark? e.g. program?query_string&other;_q_string But I tried your solution but it doesn't help... Thanks anyway.[/quote] That is true, but with your URL you have your first question mark hidden. Your URL: http://www.myserver.com/index.php/login/...iew/secret The first question mark is hidden after index.php: http://www.myserver.com/index.php?/login/index/?ref=http:/2Fwww.myserver.com/index.php/administration/overview/secret So you are basically adding 2 question marks to your URL. |
Welcome Guest, Not a member yet? Register Sign In |