Welcome Guest, Not a member yet? Register   Sign In
URI Routing
#1

[eluser]huzzi[/eluser]
Hi Guys!!

Need help creating route for thing:

/member/login/<anything> => /member/login

I've tried this but doesn't seem to work.

Code:
$route['member/login/:any'] = "member/login";

I like to specify return url to the login page and after authenticating the user send them back to the page.

Example url: http://www.mydomain.com/member/login/?re...ber/secure

Or is there a better why to achieve this?

Many thanks.
#2

[eluser]Dam1an[/eluser]
It would be much cleaner to set the uri_string as a session var before redirecting them to the login page, and then use that for the redirect
#3

[eluser]Thorpe Obazee[/eluser]
edit: nevermind Smile
#4

[eluser]xwero[/eluser]
use a hidden input that stores the current url. When visitors submit the login form you the current url gets posted and you can use it to redirect.
#5

[eluser]huzzi[/eluser]
[quote author="Dam1an" date="1242740234"]It would be much cleaner to set the uri_string as a session var before redirecting them to the login page, and then use that for the redirect[/quote]

Thanks, got it working with session. Smile




Theme © iAndrew 2016 - Forum software by © MyBB