I have different themes for Administration and for my front end. I'm using WebFM in an admin context, and it doesn't work well in my own front end theme, so I'd like to be able to 'force' it to use the theme I've specified for Administration.

Any help or pointers would be appreciated.

Comments

tcowin’s picture

Status: Active » Closed (fixed)

Never mind - I think I've figured it out - by using:

http://drupal.org/node/122578

and adding the optional trigger if arg(0) == 'webfm'

it appears to work as desired

jsims281’s picture

Great, that was very useful thanks for that link.

full micro module for anyone who wants a copy paste solution:

webfm-themechanger.module =

<?php
/**
* @file
* Module definition for webfm-themechanger.
*/
  if (arg(0) == 'webfm') {
      global $custom_theme;
      $custom_theme = variable_get('admin_theme', '0');
      drupal_add_css(drupal_get_path('module', 'system') .'/admin.css', 'module');
  }
?>

webfm-themechanger.info =

; $Id$
name = "Web FM Theme changer"
description = "Changes the theme to the default admin theme on the webfm page."
core = "6.x"

Edit: I'm using this in Drupal 6 and it seems to be working. If anyone has any updates specific for D6 please let me know!