I'm getting a redirect loop when using Login Toboggan. It doesn't happen all of the time and I think I've narrowed it down to something with the session, specifically the active-tabs[last-active-href] value.

Since it's intermittent, I was able to print out a session of a working copy and a non-working copy. Here are both:

WORKS -- Array ( [active-tabs] => Array ( [last-active-href] => index ) ) toboggan/denied

DOESN'T WORK -- Array ( [active-tabs] => Array ( [last-active-href] => user/register [user] => user/register ) [wantsEvents] => [wantsResources] => [wantsSupport] => ) toboggan/denied

I've also noticed that if I comment out the following line the redirection loop stops (although no page loads):

$return = menu_execute_active_handler('user/register');

Any ideas? I'm at my wits end.

P.S. I'm not exactly sure which version I'm using, so I've included this comment from the top of the module:
// $Id: logintoboggan.module,v 1.133.2.24 2009/10/16 14:30:15 thehunmonkgroup Exp $

Comments

hunmonk’s picture

Priority: Critical » Normal
Status: Active » Postponed (maintainer needs more info)

I've also noticed that if I comment out the following line the redirection loop stops (although no page loads):

$return = menu_execute_active_handler('user/register');

where are you commenting out this line of code?

i've never had anybody else report this before, so i'm guessing it's not related to LT.

what is this 'active-tabs' stuff in the session? i don't think that's coming from core, and definitely not coming from LT. do you have some other contrib installed that's inserting that? perhaps you should try disabling that module if so and see if it fixes the issue.

iansilber’s picture

Ah ha! Thanks for pointing me in the right direction. I did a search through my sites/modules directory and found that it was coming from the Smart Tabs module. I disabled the Smart Tabs module and now I don't get the redirection loop anymore!

Maybe this should be documented somewhere in the module docs.

hunmonk’s picture

Project: LoginToboggan » Smart menus Smart tabs
Version: 6.x-1.7 » 6.x-1.x-dev
Status: Postponed (maintainer needs more info) » Active

reassigning to appropriate queue.

stephanbauer’s picture

Is happening to me when trying to access
admin/build/themes/settings/{some theme}
the second time.

rdeboer’s picture

Assigned: Unassigned » rdeboer

Thanks for the test case, Stephan. Will investigate.

ki’s picture

Same "infinite redirect loop" happened to me on search page, search/*.
I spent hours until I determined Smart Tabs module was responsible for it.
Then I stumbled on this page, which gave me clue to solve the problem.

On the admin settings page under the section "Pages to exclude from the collection specfied above:" (note misspell btw), add "search/*" into the entries (without quotes) and the problem is solved.

rdeboer’s picture

Of the alleged infinite redirects in #1 ("user/register"), #4 ("admin/build/themes/settings/...") and #6 ("search"), I could only reproduce #6.
#6 comes about because for some reason core's menu router table states that "search" is the child of "search/node", rather than the other way around.

When infinite redirects occur the fix is the same: put the URL of the page on which the tabs reside on the exclusion list (Administer >> Site configuration >> Smart tabs). As Ki mentions in #6 this means to add "search" to the page exclusion list.

In the version 6.x-1.6 or later I have made "search" part of the default exclusions, so users won't have to do this as part of the installation. I have also updated the project page.

rdeboer’s picture

Category: bug » support
Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.