This is a migrated thread and some comments may be shown as answers.

EnableEmbeddedBaseStylesheet Odd Behavior

3 Answers 158 Views
Menu
This is a migrated thread and some comments may be shown as answers.
digitall
Top achievements
Rank 1
digitall asked on 21 Nov 2012, 08:01 PM
I have a RadMenu instance defined on a master page like this:

<telerik:RadMenu runat="server" ID="rdMenu" Skin="CustomSkin" EnableEmbeddedBaseStylesheet="false" EnableEmbeddedSkins="false" DataSourceID="menu" />

For the main page of the site (not in a subfolder), this works exactly as expected - I have a CSS file that is linked to the page which contains both a modified version of the base stylesheet plus the contents of my custom skin's CSS. The problem I'm having is any page on a subfolder seems to be having the EnableEmbeddedBaseStylesheet property ignored so I get a reference to WebResource.axd for the base which throws off all of my CSS.

Any guesses as to what would cause this property to be selectively applied when it should always be in effect? I'm on version 2012.3.1016.45.

3 Answers, 1 is accepted

Sort by
0
Boyan Dimitrov
Telerik team
answered on 23 Nov 2012, 04:55 PM
Hello digitall,

Although EnableEmbeddedBaseStylesheet is set to false in case of having any controls on the page that have context, filtering or any kind of menu, this would load the WebResource.axd and ignore that property, thus overriding your custom base styles. This might be the reason for the described unusual behavior that you are facing.

Kind regards,
Boyan Dimitrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
digitall
Top achievements
Rank 1
answered on 26 Nov 2012, 05:57 PM
So what's the best way around this? My main menu instance needs to not indent by ~50px since I don't have that left column image (seen with the default skin here: http://demos.telerik.com/aspnet-ajax/menu/examples/overview/defaultcs.aspx), but other pages have grids which are likely loading context menu options (and with that, the base stylesheet/webresource.axd reference) even though I'm not using the context menus.
0
Boyan Dimitrov
Telerik team
answered on 29 Nov 2012, 02:52 PM
Hello,

Each menu item has style property padding-left set to 28px that is remain for icon if used. Please keep in mind that setting that property value to 0px would ignore that gap and place your text next to the left border. This would be an easy convenient workaround instead of disabling the base style sheet and the embedded skins. Please follow this approach in order to clear your menu items padding-left:

<style type="text/css">
        .RadMenu .rmGroup .rmText {
            padding-left: 0px !important;
        }
    </style>

Hope that this will lead you into right direction.

Regards,
Boyan Dimitrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Menu
Asked by
digitall
Top achievements
Rank 1
Answers by
Boyan Dimitrov
Telerik team
digitall
Top achievements
Rank 1
Share this question
or