Announcement

#1 2013-08-18 21:16:45

chrisa
Member
2013-06-08
11

Redirect on logout

Hi

We're using PWG as a module in our website.  A requirement we have is to define which page the user gets redirected to when they click logout.  (btw, I tried capturing the logout event in a plugin and was unable to get it work).

Please could you make the following change:


In file include/user_inc.php
line: 33

    if ($conf['redirect_on_logout'])
      redirect($conf['redirect_on_logout']);
    else
      redirect(get_gallery_home_url());

I can then define the conf variable to the page I wish to redirect the user to in the local config.

Thanks
Chris

Offline

 

#2 2013-08-18 22:01:14

flop25
Piwigo Team
2006-07-06
7037

Re: Redirect on logout

hi
what did you try with the trigger?


To get a better help : Politeness like Hello-A link-Your past actions precisely described
Check my extensions : more than 30 available
who I am and what I do : http://fr.gravatar.com/flop25
My gallery : an illustration of how to integrate Piwigo in your website

Offline

 

#3 2013-08-24 21:44:13

chrisa
Member
2013-06-08
11

Re: Redirect on logout

Previously, for some reason it wasn't calling my event handler.

I had:  add_event_handler('user_logout', 'my_logout');

Strangely, I've just retried and it's working fine now (go figure?).

Offline

 

#4 2013-08-24 22:07:18

chrisa
Member
2013-06-08
11

Re: Redirect on logout

UPDATE: Unfortunately, this only appeared to work.

It triggers the handler fine and redirects to the new page, however, the PHP session is not terminated.

Last edited by chrisa (2013-08-24 22:07:30)

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact