Filters the currently-selected public theme. Changing the theme name through this filter will cause Omeka to use a different theme to display the public site.
Plugins can use this filter to allow the site to use different themes on different pages, or to show different themes to different users (say, a completely different site for mobile users).
Arguments
- string
$themeName
{{#if - | (optional)}}
- The currently-selected public theme.
- {{#if: | Default:
{{{default}}}
}}
Example
add_filter('public_theme_name', 'my_plugin_public_theme_name'); function my_plugin_public_theme_name($publicTheme) { if ($someCondition) { return 'different-theme'; } else { return $publicTheme; } }
Version
This filter is available starting in Omeka 1.4.
See also
admin_theme_name, the corresponding filter for the admin theme.