zoukankan      html  css  js  c++  java
  • 解决 asp.net 中如果 Menu 控件放在 MasterPage 中, IE6 会出现的二级菜单不能正确显示的问题

     

    以下是原文,我采用的是第二种方式,只加一行代码就能搞定,简单有效。第一种方式没有测试过,由于担心会影响到已测试过的其它功能,所以没有用。

     

    > A lot of users are finding that after moving their ASP.NET 1.1 site to ASP.NET 2.0 and then adding a Menu Control to their app, the Menu doesn't work.
    >
    > The reason this doesn't work is that an extra tag was added to web.config <xhtmlConformance mode="Legacy" /> This flag was meant for 2.0 to act a lot more like 1.1 and one of the major differences is the naming convention of controls. This naming change causes the quirky behavior with Menu in IE.
    >
    > There are 2 fixes for this issue:
    >
    > 1) Remove the xhtmlConformance tag from web.config
    > Personally if you can do it, I recommend this option. If you're using ASP.NET 2.0 features, you should try and stick with the new rendering modes.
    >
    > 2) If you can't do #1, then give your masterpage an ID
    > To do this, add a line to your Page_Load for your Masterpage:
    >
    > public partial class MasterPage : System.Web.UI.MasterPage
    > {
    > protected void Page_Load(object sender, EventArgs e)
    > {
    > this.ID = "Master1";
    > }
    > }

  • 相关阅读:
    【批处理】for命令
    【批处理】if命令,注释方式
    【批处理】choice命令,call 命令,start 命令,rem
    LoadLibrary加载动态库失败
    编译器如何实现静态变量只初始化一次
    汇编语言中 cs, ds,ss 的区别
    变量在内存中的位置
    call和ret指令
    函数调用
    浮动
  • 原文地址:https://www.cnblogs.com/verygis/p/1288379.html
Copyright © 2011-2022 走看看