this module doesn't seem to be able to handle back button issues. when you switch the theme, then go ahead in your page and switch back, the theme won't be changed again. in fact pressing the browser's back button should cause effects on the theme, though.

i'm working on a barrier-free website and want to use this module to let the users switch bewteen the normal view and a high-contrast view of the site (moreover with a very simple visual structure, i guess i am forced to use two themes).

how could i go on?

Comments

ycle’s picture

Status: Active » Closed (fixed)
ycle’s picture

Status: Closed (fixed) » Active
sun’s picture

Status: Active » Closed (works as designed)

SwitchTheme stores the theme to use in the user's session, so that the selection persists across further requests. If your browser does not serve the previous page from its own cache (accessed via "Back" button in the browser), then Drupal will serve the page as always, which means that the currently selected theme will be used.

This is actually by design - otherwise, all links on all pages would have to be altered to contain the &theme=theme_name query parameter to have the chosen theme persist across requests. An approach like that would be very fragile, because you only need a single link on the page that does not contain the query parameter and you'd suddenly get a different/default theme.