Click here to Skip to main content
15,867,686 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Dear all,

I have created a menu for my web page using ASP.net 2.0 Menu Control. This stuff is working fine when view in IE 8.0 but when I am testing it on Chrome, it is NOT showing the sub-menu poping sideways. Moreover the menu itself is displaying funny. The code is as under:

XML
<asp:Menu ID="Menu1" runat="server" BackColor="#E3EAEB" DynamicHorizontalOffset="2" Font-Names="Verdana" Font-Size="0.8em" ForeColor="#666666" StaticSubMenuIndent="10px">
<Items>
<asp:MenuItem Text = "Part I" Value="Part I">
<asp:MenuItem Text = "Chapter 1" Value="Chapter 1"></asp:MenuItem>
</asp:MenuItem>
<asp:MenuItem Text = "Part II" Value="Part II">
<asp:MenuItem Text = "Chapter II" Value="Chapter II" />
<asp:MenuItem Text = "Chapter III" Value="Chapter III" />
</asp:MenuItem>


</Items>
    <StaticSelectedStyle BackColor="#1C5E55" />
    <StaticMenuItemStyle HorizontalPadding="5px" VerticalPadding="2px" />
    <DynamicHoverStyle BackColor="#666666" Font-Bold="False" ForeColor="White" />
    <DynamicItemTemplate>
        <%# Eval("Text") %>
    </DynamicItemTemplate>
    <DynamicMenuStyle BackColor="#E3EAEB" />
    <DynamicSelectedStyle BackColor="#1C5E55" />
    <DynamicMenuItemStyle HorizontalPadding="5px" VerticalPadding="2px" />
    <StaticHoverStyle BackColor="#666666" Font-Bold="False" ForeColor="White" />
    <StaticItemTemplate>
        <%# Eval("Text") %>
    </StaticItemTemplate>
</asp:Menu>


The details are being picked up from Web.Sitemap file which is as under:

<?xml version="1.0" encoding="utf-8" ?>

<sitemap>
<sitemapnode url="Default.aspx" title="Home">
<sitemapnode title="Products" description="Our Products">
<sitemapnode>
url="Product1.aspx"
title="ASP.NET TicTacToe"
description="Tic Tac Toe for ASP.NET" />
<sitemapnode>
url="Product2.aspx"
title="ASP.NET Checkers"
description="Checkers for ASP.NET" />

<sitemapnode title="Services" description="Our Services">
<sitemapnode>
url="Service1.aspx"
title="ASP.NET Consulting"
description="Best ASP.NET Consulting" />
<sitemapnode>
url="Service2.aspx"
title="ASP.NET Training"
description="Best ASP.NET Training" />




Please suggest a corrective option which can help this situation (I do not want to use Javascript).

Thanking you all in advance.

regards,

IB
Posted

1 solution

 
Share this answer
 
Comments
Indrojeet_Bhattacharya 30-Jan-12 13:35pm    
Thank you very much thatraja ... your links provided me the solution.
thatraja 30-Jan-12 13:40pm    
You welcome
Member 11769365 7-Apr-18 2:52am    
Hi ,
I am using IIS6,framework 2.0,Server OS 2003 and implemented bootstrap in aspnet menu. The problem is like when i am opening application in safari browser, sub menu is not displayed also "Expand" word added along with main menu . Example if my menu is called Reporting, but it renders "Reporting Expand Reporting". This issue happening in very first load of application in safari. Once i refreshed then menu is working properly. Could you please help on this??
thatraja 15-Apr-18 23:57pm    
Screenshot would be helpful

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900