ASP.NET Menu MouseOver Problem Solution for IE8 and Safari

If you are using ASP.NET menus which open when you drag the mouse over them, you may experience difficulties in Internet Explorer 8 or Safari. They simply won’t respond to your mouseover action.

The workaround for Internet Explorer 8 is simple: Use the compability mode. However; the “solution” has been explained in . Here is the excerpt:

Setting the z-index property (HTML) using CSS can address this problem. The CSS class would look something like this:

  1. .adjustedZIndex {
  2. z-index: 1;
  3. }

And the Menu should look like as below

    1. asp:Menu ID="Menu1" runat="server"
    2. DynamicMenuStyle CssClass="adjustedZIndex" /
    3. /asp:Menu

The z-index has to be something higher.

I have set the z-index property as 99, and it worked like a charm.

The solution for Safari has been explained in . Here is the excerpt:

What I did to enable the asp:menu for Safari was to add a file called safari.browser to the App_Browsers folder. The contents of safari.browser are as follows:

<browser refID="safari1plus">
<adapter controlType="System.Web.UI.WebControls.Menu" adapterType="" />

Basically the refID matches a browser id in the original browser configuration files for the .Net framework. In our custom .browser file we override the control adapter settings for the asp:menu control for this specific browser.

I have tested this on Mac OS Snow Leopard, and it worked like a charm.

Both of these solutions can be implemented together.








Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s