This module is golden, but it has one pretty important flaw, at least in the role I would like it to assume(I expect it would be a popular application though). When this module is used for navigation blocks which are consistently displayed throughout a site, it will reset to the default tab on every page load. So, if a user wishes to select another item from the same tab, and its not the default, it will have to be reselected. That's going to leave the user pretty irritated upon much repetition.

Is it possible to prevent the tabs from being reset with every page load?

Thanks for reading.

Comments

bcn’s picture

+1 to this request...

Upon a quick glance at the JavaScript (jquery) it looks like the first child is being set active on each page load, which results in the tabs being reset each time. Obviously there are use cases for both scenarios, the question is how difficult it would be to retain some state across page reloads.

In any case, many thanks for your hard work on this module!

thatnewguy’s picture

I looked around to see if any other modules provided the same functionality and the tabbed block module seems to keep your tab selection across page loads.

http://drupal.org/project/tabbed_block

It's a good module that provides similar functionality but lacks the theming that this one has available. So if you don't mind doing your own theming it's a good alternative until the problem is solved with this module.

katbailey’s picture

Hi thatnewguy,
have you actually seen this working? I was curious as to how it was done and checked out the module. It sets cookies which seem to be for this purpose but the tabs are being reset on page load. Does it work for you?

Katherine

thatnewguy’s picture

Yup, I have it installed on my test site along with your module. I have noticed that if you change pages very quickly, it will lag a small amount and you can observe the same reset on page load that your module has but then automatically it will select the tab you were on. Without any lag it appears as if it just remains unchanged.

bcn’s picture

Hi Katherine,

I also tried the tabbed_block module and while it is setting cookies, I can confirm that (as you stated) the tabs being reset on each page reload. I think it has some JS issues with how the cookie is being set, which kinda takes the wind out of it's sails :(

Would could consider patches which used cookies to remember the active tab's state across page loads. If so, I was thinking it would be nice to be able to disable this feature on a per block basis, as some people might want the blocks to reset on page load..

Your thoughts?

katbailey’s picture

Category: support » feature

This feature is being worked on and will be added soon

Anonymous’s picture

This is exactly what I could use but for Drupal 6.X. Is there an update as to progress or any ETA? Thanks!

highvoltage’s picture

Is this feature in the works for 6.x?

wayne57’s picture

sorry this is repeated but...Will this be added to version 6.x ?

mmader’s picture

Version: 5.x-1.2 » 6.x-2.x-dev

In the mean time, you can implement a quick and dirty solution that I posted in another thread.

sped2773’s picture

I tried out mmader solution in #10 and this works fine until you turn caching on, at which point it will only every render the page with the tab
that was selected when the page was cached, I guess there needs to be a client side solution where the cookie is read and set on page load.

Anyone got any ideas for this?

tayzlor’s picture

has there been any traction on solving this issue, i'm trying to display a multi-step form inside one of the tabs, and whenever i submit to the next step, the page will reload, and the tab will also reset itself back to the default tab (which is not the one my multi-step form is on) =(.

Edit: there seems to be some work over here on the issue - http://drupal.org/node/354199 , so i've posted in there in the hope the guys will roll-up a patch to solve this problem

katbailey’s picture

Status: Active » Closed (duplicate)

Marking as a duplicate of #354199: Remember last clicked tab