4

How can I get the user/%/edit page to use the admin theme that is used for the rest of the site?

5

That path is already one that will use the admin theme if the current user has the correct permissions to access it.

Try going to http://mysite.com/admin/people/permissions and checking the "View the administration theme" permission for the roles you wish to be able to use the admin theme.

It'll definitely work as the User module implements hook_admin_paths() to define that path as an admin page:

function user_admin_paths() {
  $paths = array(
    'user/*/cancel' => TRUE, 
    'user/*/edit' => TRUE, 
    'user/*/edit/*' => TRUE,
  );
  return $paths;
}
| improve this answer | |
  • Thank you it was so helpful! Also themekey module can help but Code is always faster! thanks – werqious Jun 28 '12 at 15:52
  • 1
    also we can use 'hook_admin_paths_alter()' – werqious Jun 29 '12 at 9:32

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.