I want the administration theme for all the default pages, except one: /user/%/edit

How do I get the default theme to display for this page instead of the administration theme?


For Drupal 7 you can use Administration theme or hook_admin_paths_alter() in your custom module.

 * Implements hook_admin_paths_alter().
function my_module_admin_paths_alter(&$paths) {
  $paths['user/*/edit'] = FALSE;

For Drupal 8, see https://www.drupal.org/node/2224207.


I believe ThemeKey allows you to control that: https://drupal.org/project/themekey

If that doesn't work, you can force a specific theme for a page using: https://api.drupal.org/api/drupal/modules%21system%21system.api.php/function/hook_custom_theme/7

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.