Coffeehouse Thread

15 posts

Forum Read Only

This forum has been made read only by the site admins. No new threads or comments can be added.

IE CSS Support Blows

Back to Forum: Coffeehouse
  • User profile image
    Cairo

    Why must CSS support in IE be so poor?



    http://doxdesk.com/software/js/fixed.html


    Fixed positioning

    According to CSS level 2, an element can be positioned relative to the browser window using the style position: fixed: it does not move when the page is scrolled. You can do nice layout things with this in most modern browsers - but not on IE for Windows. Unless you use this script.

    Fixed backgrounds

    According to CSS level 1, an element’s background can be positioned relative to the browser window using the style background-attachment: fixed: the body of the element acts like a window onto the background image, which stays still when the page is scrolled. You can do nice layout things with this in most modern browsers... but, again, not correctly on IE/Win. (Unless, etc.)

    Using fixed.js

    This script makes these CSS properties work correctly in IE/Win version 5.0 upwards. Just insert a link to the module anywhere in your HTML (eg. in <head>):

    <script type="text/javascript" src="fixed.js"></script>

    And add whatever fixed features you like to your stylesheet as normal. On other browsers the script will silently do nothing.

    Caveats

    IE still doesn’t know that fixed-position elements should not make the window bigger. The upshot is that if you make a fixed-position element larger than the window, you can get a page that will carry on scrolling down past the bottom of the proper page. (This is usually not too bad.)

    Don’t put loads of fixed position/background elements on a page - it’ll get slow for many users.

  • User profile image
    W3bbo

    Dude, don't double-post.... there's an InternetExplorerWiki listing all these, just click on "Wiki" in the top right hand corner

  • User profile image
    Cairo

    I'm sorry, the "double-posting" bug will be fixed in IE7. See you then.

    /Cairo didn't see InternextExplorerFeedback link in the wiki section.

  • User profile image
    Cairo

    The script hacks to make IE (sort of) support CSS positioning result in very odd scrolling behavior. Is there any way to fix that?

    If there is no way to make IE work right with fixed positioning, is there an alternative? Or is table-based layout and image slicing the only working option in IE (jeez, feels like NN4)?

  • User profile image
    Cairo

    The CSS property list-style-image: url(); seems to work, except that the bullets are up and to the left of the text, rather than where the bullets sohuld be next to the text. Is there a work-around for this bug?



  • User profile image
    Maurits

    In the past I've used an IE javascript hack as a substitute for position: fixed.  Basically: use position: absolute; then have a javascript function update the top and left coordinates depending on the position of the page in the viewport.  No way to get around the jitter effect.

    The position of bullets is not determined by the spec so that's not really a bug, more of a stylistic difference between IE and other browsers.  You could use conditional comments to include an IE-specific stylesheet that specified margins/padding etc. on < ul > elements, to put the buttons where you like them.

    But if you really need to specify things to that degree of precision, < ul > elements are probably not for you... you might look into using a < table > element to position images.

  • User profile image
    W3bbo

    Cairo wrote:
    The CSS property list-style-image: url(); seems to work, except that the bullets are up and to the left of the text, rather than where the bullets sohuld be next to the text. Is there a work-around for this bug?


    Learn CSS first... use the "list-style-position: inside | outside;" property

  • User profile image
    Sampy

    Man I don't miss developing for the web.

    Give me the Smart Client any day!

  • User profile image
    ZippyV

    Looks like Bungie has a better script for fixed stuff:

    http://www.bungie.net/

  • User profile image
    Cairo


    Thanks, ZippyV. I'll dig through that stuff to see what they're doing.

    So the current rendering engine is named "Trident IV"? How old is it? What were the first three?


  • User profile image
    DMassy

    Hi Cairo,
    Trident is the codename for mshtml.dll which is the core HTML and CSS parsing and rendering engine in IE. There's no such thing as "Trident IV" so I'm not sure where that term comes from although there have been several versions of mshtml.dll over the years since it was first introduced with IE4 in 1997.
    You've already been pointed at the IE Wiki as a great place to leave feedback. In general comments like "IE CSS Support Blows" are less than helpful. As CSS usage has increased over the past few years we have definitely become aware of inconsistencies in our CSS support that we know developers find frsutrating. Although I certainly can't promise to address every issue (and if I did make such a promise you'd be right to be cynical) we are certainly looking to see what can be done to improve things. Feedback is definitely appreciated especially when it is detailed, clearly explains the issue and why it is so critical to address. That way we can focus on addressing the more critical issues first.

    Thanks
    -Dave Massy
    Senior Program Manager
    Internet Explorer

  • User profile image
    DMassy

    Actually thinking about it I guess we are on "Trident IV"

    • IE4 - Trident I
    • IE5.0 - Trident II
    • IE5.5 - Trident III - There were more enhancements in IE5.5 than many people realised. Although we only called it a .5 release for Trident it had more enhancements that some other releases.
    • IE6 - Trident IV

    So now we are working on "Trident V" but generally we refer to it just as Trident and the version of IE that it shipped with rather than the version of Trident.

    Thanks
    -Dave

  • User profile image
    Cairo

    Hello DMassy,

    Thanks for the reply. I realize my subject like was somewhat incindiary, but you can also think of it as honest.

    Feedback is definitely appreciated especially when it is detailed, clearly explains the issue and why it is so critical to address. That way we can focus on addressing the more critical issues first.

    I think I left two very clear pieces of feedback, one concerning CSS and the other concerning PNG. This thread is about CSS.  I included specific examples and references to external sites with more information. More explanation follows.

    A number of years ago, the norm was to get a page working in IE, then spend extra time to make Netscape Navigator 4 work well with it. Today the situation is reversed. Gecko, KHTML and Opera are all much more  capable and consistent where open standards support is concerned (e.g., CSS and PNG, XML/XSLT), and now the extra time is spent making IE work well with it. Often, IE's Netscape-era rendering model vetoes use of time-saving and site-enhancing capabilities, such as use of CSS features like position: fixed, and requires use of a table-based layout and image slicing. The result is more difficult to maintain, slower to render, slower to download (due to more data, split into more pieces) and less capable than designs that use the capabilities of modern browsers. IE's poor CSS support is an issue for both developers and users. Because of IE, time and resources are wasted on a routine basis, and the user experience is diminished.

    I am indeed cynical about Microsoft fixing problems with IE. I have not given up hope, of course, which is why I'm posting. I really can't give up hope unless IE loses enough market share that it becomes the NN4 of the new millenium.

    Please, I beg you, prove me wrong.  Fix IE's problems. I don't understand why Microsoft will not or cannot fix IE, except by releasing "IE7". Which means of course, that Microsoft will essentially never fix them, as IE7 is Longhorn-only. The legions of people using 95, 98, 98SE, ME, 2000 and XP will be stuck with the current IE, unless - as I hope they will - they download and use Firefox. IE7 is years off in any case. So we all party like it's 1999.

    My cynical theory for why fixes are being delayed until IE7 is as follows.
    1. Supporting CSS and PNGs levels the playing field among browsers (by raising IE's level), thus reducing the "value-add" (*cough*) of IE today. It also encourages use of those features: see #2 and #3.
    2. IE7 is slated to support XAML, Microsoft's replacement for the open internet and web standards.
    3. Once XAML is in place, there will be no reason to properly support CSS,  PNGs and the like. "Use XAML" will be the standard answer.

    Anyway, back to being hopeful.

    Dave Massey, Senior Program Manger for Internet Explorer, please help. We're all counting on you. Make posts like mine a thing of the past.







  • User profile image
    DMassy

    Hi Cairo,
    We're definitely listening and taking note. It's too early to discuss details andschedule at this timebut we are definitely aware of issues adn working on them.
    Item 2 of your list is a little off though:

    • 2. IE7 is slated to support XAML, Microsoft's replacement for the open internet and web standards.

    I'm not sure where you got this idea. XAML is a declarative XML language for hooking up .NET components. It happens to be particularly useful for declaring the functionality that will become available in Avalon the codeword for the next generation presentation subsystem for windows. It certainly isn't positioned as a replacement for the web content HTML and CSS recommendations from the W3C. We're committed to providing a great web browsing experience as part of Windows in the future and looking forward to the work ahead.
    Thanks
    -Dave

  • User profile image
    Cairo

    We're definitely listening and taking note. It's too early to discuss details andschedule at this timebut we are definitely aware of issues adn working on them.

    Dave,

    Thanks! The solution can't arrive too early.

    -M

Conversation locked

This conversation has been locked by the site admins. No new comments can be made.