Skip to main content
Topic: [ADDON] LILOR: Log In Log Out Redirect (Read 1817 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[ADDON] LILOR: Log In Log Out Redirect

LILOR: Log In Log Out Redirect

Thank you for using/testing it.

Yours friendly,
Abu Fahim Ismail.

BSD3. Feel free to modify but try to keep author's link if it is in there somewhere. ;)

#Change Logs

@Version 1.0.1
- Fix incorrect uninstall.

@Version 1.0.0
- Initial release.

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #1

This mod is not fully hook yet because I have not test it using action hooks for it i.e. integrate_action_login_after and integrate_action_logout_after. I forgot all about it until I review other posts relating to hook.

Do you think that these modification code can be added via the above mentioned action hooks instead?
1. integrate_action_login_after
Code: [Select]
	global $modSettings;
if (!empty($modSettings['login_redirect_enable']) && !empty($modSettings['login_redirect_url']))
{
if (empty($_SESSION['login_url']))
$_SESSION['login_url'] = $modSettings['login_redirect_url'];
}
2. integrate_action_logout_after
Code: [Select]
		global $modSettings;
if (!empty($modSettings['logout_redirect_enable']) && !empty($modSettings['logout_redirect_url']))
{
if (empty($_SESSION['logout_url']))
$_SESSION['logout_url'] = $modSettings['logout_redirect_url'];
}

I will test later when I am on my own laptop.

Edited: Naaah... I can test it here too and it is working. It is fully hook now.

Edited again: Noooo... It was the leftovers from the unhook version. It's not working. :( :( :(

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #2

#Change Logs

@Version 1.0.1
- Fix incorrect uninstall.

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #3

Just to be sure on what I'm going to ask: what does the addon do?
Bugs creator.
Features destroyer.
Template killer.

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #4

Redirect on login and/or logout.

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #5

I'm pretty sure I have understood where it does redirect, but if I were a "normal" user, I would ask "are not members already redirected on login?".
So, I guess the description is something like:
QuoteWhen a member logs in, usually ElkArte sends him to the last page he was visiting (sort of :P), this addon changes the behaviour, redirecting any member that has performed a login to a page chosen by the admin.
Just because these days I'm in a psychopathic mood. :P
Bugs creator.
Features destroyer.
Template killer.

Re: [ADDON] LILOR: Log In Log Out Redirect

Reply #6

Yup. That should be right. He will be redirected to a page chosen by admin on login and logout via this addon.