Admin menu not there

Topics: ASP.NET 2.0, Business Logic Layer
Sep 8, 2011 at 8:14 AM

I have no admin menu. I'm have just installed and am using xml for everything (so default config really)

When I login with the default admin account (or my own account which I set as admin when setting up locally) the only menu items under the Administration side menu widget are "My Profile" and "Change password" and when actually on the admin section there is no admin menu. 

Looking at my profile (and the default admin profile) I can see we both have the Administrators role ticked. 

Checking my web.config I found that the roleManager node was missing the cookieName=".BLOGENGINEROLES" attribute, which I have added as suggested in another post but it doesn't resolve the problem.

Sep 9, 2011 at 7:01 PM

The Admin pages work, but there's no menu to get to them - any ideas on what's happening?

Sep 10, 2011 at 1:05 AM

The Administration widget and the menu at the top of the control panel mostly comes from menu.ascx.cs in the admin folder.  It looks at Web.sitemap in the root folder to see which items/nodes in the sitemap are accessible to you.

You could try removing the "rights" attributes in the Web.sitemap to see if that makes a different.  You'll see in Web.sitemap those attributes that look for example look like: rights="AccessAdminPages".  You could try removing that part completely to see if it makes a difference.

If that doesn't make a different, in menu.ascx.cs, you could try updating the line below (line 99):

adminNode => adminNode.IsAccessibleToUser(HttpContext.Current)).Where(

... changing that line above to:

adminNode => true).Where(

I'm not sure if that will help, and if so, why it is not working currently.

This menu.ascx.cs file is for the .ASPX pages.  I think the CSHTML pages (dashboard, themes, extensions) has its own version of this control.

Sep 10, 2011 at 6:26 PM

Ben - thanks.

I re-uploaded the sitemap file and the menu reappeared, so I guess there was something that was bad in the version I'd previously uploaded.