Hi!

I don't want the admin theme showing on the user and user edit pages.

I have tried:
user*
user/*/edit
users*

and nothing works.

There was a ticket raised for version 6 that was very similar, but that solution doesn't work for version 7/

Any help would be great!

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dgastudio’s picture

Priority: Normal » Major

same here, doesnt work for user edit pages.

tinny’s picture

I have the same problem but for content editing pages.

If i check Pages > Content editing and in Custom > Do NOT display on following > node/add/type

the admin theme still shows on the page node/add/type

even though it says If a path appears here, the administration theme is not shown even if all above options apply.

I got around this by
1. unchecking Content editing
2. use admin theme on node/add/*
3. do not use on node/add/type

also, no admin theme on user/* doesnt work for me either.

denny84’s picture

Do one thing. You will not need this module to overcome this problem. This solution will work for all users except user #1.

1. Create a new user role at admin/people/permissions/roles namely Sub Administrator or something meaningful.

2. Go to admin/people/permissions/list and look for the permission View the administration theme

3. Uncheck that for all roles (it will already be unchecked by default).

4. Give appropriate permissions to the new Sub Administrator and perhaps to other user roles as well, depending on your requirements.

Thats it now all the administrators and authenticated users will have normal theme instead of admin theme, except user 1. This could be bug only. But if user 1 bug works for you then may I did something wrong.

tonessss’s picture

FileSize
18.48 KB

user* works if the permissions are set correctly for Anonymous User:
Capture

sepph’s picture

Hi,

I was having the same issue.

You might find you need to uncheck the View the administration theme permission option under System. It looks as though it overrides anything you set using the Administration Theme module.

I unchecked this option. Then set Use administration theme on the following pages to admin/* and Do not use administration theme on the following pages to user/* and this allowed me to use the site theme on the user/*/edit pages.

It doesn't work for user 1 though as they've got all rights granted I believe... which can trip you up when developing. Try using another user account.

Hope this helps.

benys’s picture

FileSize
626 bytes

Drupal 7 intruduce hook_admin_paths() to detect admin paths.
I implemented hook_admin_paths_alter to override admin paths.

jordi_bcktt’s picture

Working for me. Thanks.

marcvangend’s picture

I'm not sure if #6 is the best solution. Instead of implementing another hook, let's try to keep the logic in a single place. It looks like problems like this can be prevented by explicitly returning the default theme name when $admin_theme_disallow is true.

So around line 148 of admin_theme.module you would get:

  // we should not show the admin theme if the user has no access or the path is in the disallow list
  if (!user_access('access admin theme') || $admin_theme_disallow) {
    return variable_get('theme_default', 'bartik');
  }
marcvangend’s picture

On second thought, maybe #6 is the better solution. This is untested... but I guess that if you force the default theme without altering the admin paths, then Overlay module will try to render pages with the default theme inside the overlay.

heylookalive’s picture

Patch on #6 works for me!

asak’s picture

Yep - #6 works like a charm.

willieseabrook’s picture

Status: Active » Reviewed & tested by the community

#6 works for me. That make 3 confirmations by community. Setting to RTBC

heylookalive’s picture

Issue summary: View changes

Works for me, can we commit?

sgabe’s picture

Patch in #6 works for me too.

Scott Robertson’s picture

#6 works for me as well.

imclean’s picture

Version: 7.x-1.0 » 7.x-1.x-dev

Works for me. Updating version.

imclean’s picture

Status: Reviewed & tested by the community » Needs review

May need some testbot action first.

kalistos’s picture

FileSize
626 bytes

Renamed patch file name.

lodey’s picture

#18 worked well for me. It would be useful to have it in the dev version at least.

I'd say this is the most common reason for using the module I come across - i.e. the 'user' page is part of the main site - even for admin users.

joshmiller’s picture

Status: Needs review » Reviewed & tested by the community
drupalfan2’s picture

Is this patch still necessary for latest Drupal 7 version?

Ada Hernandez’s picture

FileSize
568 bytes

#18 doesn't apply to 7.x-1.1, so creating a new one but any change done.

  • justy committed 75eaf52 on 7.x-1.x
    Issue #1227704 by kalistos, benys, Adita, tonessss: Cannot set admin...
justy’s picture

Rolled up this patch to the latest dev version.

justy’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.