menu control in master page does not get styles in ie 6.0

Last post 06-08-2009 4:27 PM by konanki. 14 replies.

Sort Posts:

  • menu control in master page does not get styles in ie 6.0

    12-21-2006, 2:52 AM
    • Member
      55 point Member
    • rokasoft
    • Member since 10-29-2002, 12:08 AM
    • Posts 18

     

    I have a menu control on a master page. it works in firefox and ie 7.0, but not in ie 6.0.

    This is a huge problem for me and I cant find any mention of it.

     Can anybody help me?

     

    Ron

    Ron
  • Re: menu control in master page does not get styles in ie 6.0

    12-21-2006, 8:44 AM
    • Contributor
      4,775 point Contributor
    • Adam.Kahtava
    • Member since 10-18-2006, 2:14 PM
    • Canada
    • Posts 927

    You'll need to be more specific:

    What is rendered into the HTML Head tag of your problem page?

    What does the CSS look like?

    Can you post the rendered HTML source? 

    Can you show us a live demo? 

    What do you think the problem is?

  • Re: menu control in master page does not get styles in ie 6.0

    12-21-2006, 11:23 AM
    • Member
      55 point Member
    • rokasoft
    • Member since 10-29-2002, 12:08 AM
    • Posts 18

    Adam,

    Thanks for responding.

    The problem occurs whrn the menu is on a master page, and displayed in IE 6.0

    IE 7.0 works as does firefox/mozilla.

    look at http://rokasoft.com/menutest.aspx and http://rokasoft.com/menutest3.aspx

    these pages are problematic

    http://rokasoft.com/menutest4.aspx works. it is the same code, but not using a master page

    I'm baffled. I havent found any other people with this problem.

     thanks,
    ron

     

     

     

    Ron
  • Re: menu control in master page does not get styles in ie 6.0

    12-21-2006, 12:55 PM
    • Contributor
      4,775 point Contributor
    • Adam.Kahtava
    • Member since 10-18-2006, 2:14 PM
    • Canada
    • Posts 927

    The underscore (_) in CSS class names is only valid in the CSS 2 specifications, IE 6 doesn't support this level of CSS.

    Your page will display fine If you remove the underscore from all your CSS class names.

    See the The Underscore Hack

  • Re: menu control in master page does not get styles in ie 6.0

    12-21-2006, 2:02 PM
    • Member
      55 point Member
    • rokasoft
    • Member since 10-29-2002, 12:08 AM
    • Posts 18

    First of all, thanks A MILLION for responding!

     Considering that these styles are autogenerated by .net, (by concatenating the master page place holder name to the menu id and adding a _) is there an easy way to fix that?

     Also, isnt it bizarre that the code generated by visual web developer creates code that doesnt work with ie 6.0?

    are there any properties of the menu that may tell it to generate is differently? is there something called "uplevel"?

    I really appreciate your help. This master page issue is killing me!

    Ron
  • Re: menu control in master page does not get styles in ie 6.0

    12-22-2006, 10:02 AM
    Answer
    • Contributor
      4,775 point Contributor
    • Adam.Kahtava
    • Member since 10-18-2006, 2:14 PM
    • Canada
    • Posts 927

    Your finding may have huge implications...

    Out of curiosity what are your placeholder names? Are any of them prefixed with the underscore?

    IE doesn't like CSS names, classes, or id's that begin with the underscore - underscores within names, classes and id's are ok.

    Bad:

    #_idTest{
        color: red

    ._classTest{
        color: red

    _color: red;

     
    OK: 

    #id_Test{
        color: red

    .class_Test{
        color: red

  • Re: menu control in master page does not get styles in ie 6.0

    12-26-2006, 2:57 PM
    • Member
      55 point Member
    • rokasoft
    • Member since 10-29-2002, 12:08 AM
    • Posts 18

    Adam,

     

    The problem is im using visual web developer and master pages.

    the VWD is creating the class name by concatenating _ctl0_ to the menu item

     any idea how i can avoid this?

     

    ron

    Ron
  • Re: menu control in master page does not get styles in ie 6.0

    01-10-2007, 4:17 AM
    • Member
      17 point Member
    • khaled_zs
    • Member since 03-09-2005, 6:36 AM
    • Posts 5

    ok ron

    try to remove this setting tag "<xhtmlConformance mode="Legacy"/>" from the web.cofig file

    this will convert the prefix _ctl0 to be ctl0 and will solve your problem.

    i faced the same problem you have and i found this solution in the link http://weblogs.asp.net/scottgu/archive/2006/04/18/Great-New-Advanced-Article-on-ASP.NET-2.0-Master-Pages.aspx and my problem was solved.

    i hope the same to you

     khaled

     

  • Re: menu control in master page does not get styles in ie 6.0

    01-10-2007, 8:29 AM
    • Contributor
      4,775 point Contributor
    • Adam.Kahtava
    • Member since 10-18-2006, 2:14 PM
    • Canada
    • Posts 927

    Thanks, khaled.

    This is just what I was looking for.. :) 

  • Re: menu control in master page does not get styles in ie 6.0

    01-10-2007, 8:43 AM
    • Member
      55 point Member
    • rokasoft
    • Member since 10-29-2002, 12:08 AM
    • Posts 18

    Khaled,

    I have not tried it yet, but I imagine it will work and I thank you in advance.
    In the meantime, I actually had to de-implement my master page and do it the old fashioned way. :(

     

    Ron

    Ron
  • Re: menu control in master page does not get styles in ie 6.0

    01-10-2007, 9:09 AM
    • Member
      4 point Member
    • ilvc
    • Member since 06-28-2006, 3:27 PM
    • Posts 3
    Thanks to ALL of you for this disscussion.  First  I post some half hour ago but since this forum is moderated my posting hasd not been approved yet.  I commented out the  <xhtmlConformance mode="Legacy"/> in the web.config and enclosed the menu and ContentPlaceHolder inside a div.  as for my posting  I had a problem with the menu and master pages.  You can look for it once ist gets approved or you can read my reply in this previous posting http://forums.asp.net/thread/1523023.aspx.  Again thank you all!
    ::
  • Re: menu control in master page does not get styles in ie 6.0

    02-28-2007, 7:49 AM
    • Member
      58 point Member
    • John_Idol
    • Member since 12-01-2006, 3:51 PM
    • Cork, Ireland
    • Posts 50

    Thank guys,

    this thing was driving me nuts.

    Cheers,

     

  • Re: menu control in master page does not get styles in ie 6.0

    02-24-2009, 12:22 AM
    • Member
      50 point Member
    • konanki
    • Member since 02-20-2009, 4:51 AM
    • India
    • Posts 29

    Hi,

    It is very help full to me, We struggled  lot from past 2 weeks.

    It is working fine  now  when i  commented out the  <xhtmlConformance mode="Legacy"/>

    Thanks,

    murali

    Murali Krishna.k
  • Re: menu control in master page does not get styles in ie 6.0

    05-21-2009, 6:29 AM
    • Member
      4 point Member
    • hiren.khodiar
    • Member since 11-10-2006, 12:46 PM
    • Khodiar
    • Posts 2

    Hi,

    Been struggling with the issue of placing the menu control onto a master page.

    All the menu options (submenus et al) just expand-n-collapse while visiting a page deriving from a master page.

    I've tried several solutions along with removing the removal of  <xhtmlConformance mode="Legacy"/> tag. (giving IDs to the master pages in Page_Load events etc.)

    Doesn't seem to help. In fact I encounter this problem with IE 7.0 as well.

    Would appreciate any help.

    Thanks

    - Hiren

  • Re: menu control in master page does not get styles in ie 6.0

    06-08-2009, 4:27 PM
    • Member
      50 point Member
    • konanki
    • Member since 02-20-2009, 4:51 AM
    • India
    • Posts 29

    Hi  Hiren,

    give height and width is 100% , other wise

    Send screen shot and code to me. i will look-up.

    Murali Krishna.k
Page 1 of 1 (15 items)