I love this module but it took me awhile to figure out how to provide an easy way for people to switch from iUi to my default theme and back. As is, once a user switches to this theme, they are pretty much locked in at this point. So what I did was use the following php snippet to create a page with the Switchtheme module block and then place that page as an item in my primary menu.

<?php
$block = module_invoke('switchtheme', 'block', 'view', 0);
print $block['content'];
?>

Now it works like magic and anyone can swiftly switch back and forth from iUi to the Default theme at will.

Thanks for the great module and I hope this tip helps someone out there.

Comments

drew reece’s picture

This may help me out, thanks.

One issue I'm having is that switching themes doesn't account for the different url structures eg
mysite/events <- standard theme
mysite/#_events <- iui theme

So the user gets a broken page when changing to the mobile theme when not on the home page, Is this the normal behaviour?

BenK’s picture

Subscribing...