Page 2 of 2

Re: Horizontal Category Menu

Posted: Tue Jul 14, 2009 10:15 am
by mazhar
Its working for me. Make sure that sub categories are public you haven't locked or ghosted them.

Re: Horizontal Category Menu renedering problems

Posted: Thu Jul 16, 2009 2:32 am
by mazhar
Willisski wrote:I have been playing around with this menu and it works great in firefox. but in IE8 turns all of the sub menus white. Has anyone else had these issues?

Greg
ASP.NET Menu control has some known issues with IE8, Safari and Chrome. Please read following threads to fix it for these browsers.

http://blogs.msdn.com/giorgio/archive/2 ... issue.aspx

http://geekswithblogs.net/bullpit/archi ... hrome.aspx

Re: Horizontal Category Menu

Posted: Thu Jul 16, 2009 5:40 am
by Khaliq
asp:Menu control does not work well with IE8, Chrome and Safari...

Fix for IE8
Define the DynamicMenuStyle for the asp:Menu control and set a CSS class for it.
Use a value of z-index for that class greater than 0.

Code: Select all

.DynamicMenuCssClass
{
z-index: 999;
}

Code: Select all

<DynamicMenuStyle CssClass=”DynamicMenuCssClass”/>

Fix for Chrome/Safari
Add the following code to Page_Load method of your control

Code: Select all

		if(Request.UserAgent.IndexOf("AppleWebKit") >= 0 )
		{
			Request.Browser.Adapters.Clear();
		}

Re: Horizontal Category Menu

Posted: Sun Aug 16, 2009 6:38 am
by windsurfer
Hi Mazhar
Back from vacation and still trying to figure out this menu situation, under the sample catagory there should be at least 2 subs and i am not showing any. Perhaps you could check it out at http://mysurplus.ca/default.aspx
Thanks
Wil

Re: Horizontal Category Menu

Posted: Mon Aug 17, 2009 7:41 am
by mazhar
most probably you are checking it on IE8. Apply the above fix posted by khaliq. I just checked your page in FireFox and its showing child categories.

Re: Horizontal Category Menu

Posted: Mon Aug 17, 2009 7:59 am
by windsurfer
Hi
Yes i was checking it on IE8, since i am by no means an asp programmer would it be possible for you to tell me where i would put that code.
I did in the meantime install firefox and it appears to be working, I did add some subcatagories that do show up now if only i could keep the fields in the dropdown menu the same width.

Wil

Re: Horizontal Category Menu

Posted: Fri Nov 06, 2009 4:37 pm
by DBounlom
Sorry for being ignorant, but how do you "Define the DynamicMenuStyle for the asp:Menu control and set a CSS class for it." Where does this following code go? Thanks.

Code: Select all

.DynamicMenuCssClass
{
z-index: 999;
}

Re: Horizontal Category Menu

Posted: Mon Nov 09, 2009 6:28 am
by mazhar
You put these styles in your current theme's CSS file. Under you website/App_Themes folder locate your current theme folder and put this in style.css file under that folder.

Re: Horizontal Category Menu

Posted: Mon Nov 09, 2009 1:49 pm
by DBounlom
Hi Mazhar,

Thanks for responding. I tried putting this code

Code: Select all

.DynamicMenuCssClass
{
z-index: 999;
}
in the style.css file under the current theme that we use. Within that file, I tried putting it in the second line, main panel, or store header section. None of it seemed to work. I still get white boxes in IE8.

Also, in the CategoryMenuEx.ascx I would put this code

Code: Select all

<DynamicMenuStyle CssClass=”DynamicMenuCssClass”/>
so that it looks like the following.

Code: Select all

<asp:Menu ID="CategoryMenu" runat="server" Orientation="Horizontal" BackColor="#E3EAEB" DynamicHorizontalOffset="2" Font-Names="Verdana" Font-Size="Small" ForeColor="#666666" StaticSubMenuIndent="10px">
        <StaticSelectedStyle BackColor="#1C5E55" />
        <StaticMenuItemStyle HorizontalPadding="5px" VerticalPadding="2px" />
        <DynamicHoverStyle BackColor="#666666" ForeColor="White" />
        <DynamicMenuStyle CssClass=”DynamicMenuCssClass” BackColor="#E3EAEB" />
        <DynamicSelectedStyle BackColor="#1C5E55" />
        <DynamicMenuItemStyle HorizontalPadding="5px" VerticalPadding="2px"
            BackColor="#FF9933" />
        <StaticHoverStyle BackColor="#666666" ForeColor="White" />
    </asp:Menu>
Is this correct? Thanks.

Re: Horizontal Category Menu

Posted: Thu Nov 19, 2009 12:53 pm
by DBounlom
Does anyone know specific instructions on how to get the horizontal menu to work in IE8? I am not a programmer, and I haven't been able to figure it out. :(

Re: Horizontal Category Menu

Posted: Tue Dec 08, 2009 5:40 am
by mazhar
I have uploaded the modified files having fix for IE8 and Safari in actual posts(First Post of this thread). You can make use of those updated files.

Re: Horizontal Category Menu

Posted: Tue Dec 08, 2009 5:58 pm
by DBounlom
Thanks Mazhar. I appreciate it. It works great!

If I zoom in so that the resolution is low, my horizontal menu scrolls off to the right because I guess it is too long, but the other items on the page maintain a proper ratio. Is there a way to auto fit the horizontal menu in lower resolutions?

I've tried

Code: Select all

<div style="clear: both; margin-top: 6px; text-align:-moz-center;">
and I've also tried putting in

Code: Select all

<center> ... </center>
I can't get my horizontal menu to autofit regardless of the resolution size. Thanks for any help.

Re: Horizontal Category Menu

Posted: Thu Dec 10, 2009 6:23 am
by mazhar
May be you need to set menu items width in % format instead. I am not sure but it may workout.