Loading...
 
Easy theme variations

Theme Options

Theme options are an easy way to have variations of a theme that is already installed at a Tiki site. Typically they change the “base” theme’s coloring, font style, column widths or other such details.

When a theme has one or more options, there will be a second dropdown list wherever theme selections are made or assigned in Tiki, such as the user preferences page, the Look and Feel admin page, and the theme-switching module. The option can also be activated via a URL, like
tiki-switch_theme.php?theme=fivealive.css&option=kiwi.css.

How to make a theme option

To make a theme option, create a new CSS file, add CSS rules that you want the theme option to have (that is, the selectors/properties of the base theme that you want the theme option to override), and save it in a location with a path like this: “themes/parent-theme-name/options/option-theme-name/css/option-name.css. For example, FiveAlive’s “Kiwi” theme option style sheet file is located at

themes/fivealive/options/kiwi/css/kiwi.css

If a theme already has an options directory, use that one; if not, make a new one.

Theme option background images

If the theme option has alternate background images, these can go in a new directory with the same name as the theme option, such as

themes/fivealive/options/kiwi/images/

There’s no need to modify the base CSS file, or to put anything such as an import statement in the option file, for the theme option to work. The option file is simply loaded after the base file, so it overrides properties of the base file.

Advantages

Beyond being a quick way to modify an existing theme, theme options are a good way to have a modified version of the standard Tiki themes at a site. This way, a site can have its own modification of a theme, and when the base theme is updated and installed during a site upgrade, the theme option isn’t overwritten and will still function as expected, maybe just needing to be edited if any of what it’s overriding changed.

Switch Theme

Layout

Subscribe to Tiki Newsletters!

Delivered fresh to your email inbox!
Newsletter subscribe icon
Don't miss major announcements and other big news!
Contribute to Tiki

Site Config

Shoutbox

luci, 14:22 GMT, : @Bsfez: :-D
Bsfez, 09:52 GMT, : This is really a nice Tiki !
chibaguy, 10:32 GMT, : Site admins: Be careful about editing the topbar menu, which is in a small space. I had to fix an option that should be a menuSection, to prevent overflow.
Torsten, 19:44 GMT, : hidden functionality "; recommitted in trunk, tested and working. Documentation under way on [Link]
chibaguy, 16:45 GMT, : The layout template can now be changed using the "Layout" module above. :-)