title: Faking Fixed Position in IE6
body: <p>I have a site that utilizes a bottom fixed position masthead here: <a href="http://www.entheospartners.com/newsite/" rel="nofollow noreferrer">http://www.entheospartners.com/newsite/</a></p>
  
  <p>This setup works great in all browsers except IE6, which doesn't support fixed positioning in the least, so here's what I've done:</p>
  
  <p>When an IE6 user comes to the page, I make the determination if scrolling is necessary using this bit of code:</p>
  
  <pre><code>var windowHeight = $(window).height();
  var totalHeight = windowHeight - 100; // where 100 is the sum of the top nav height + footer height
  var contentHeight;
  
  if($('#subpage-content-small').length) { // main content div for a three column layout
      contentHeight = $('#subpage-content-small').height();
  };
  
  if($('#subpage-content-wide').length) { // main content div for a two column layout
      contentHeight = $('#subpage-content-wide').height();
  };
  
  if(contentHeight &gt; totalHeight) {
      $('#container-container').css({
          'overflow-y' : "scroll",
          'height' : totalHeight
      });
  };
  </code></pre>
  
  <p>...which calculates everything correctly, puts the scrollbars where they need to be (flush right), and sets them to the appropriate height. The problem is that the scrollbars don't move the content. I can't say that I've ever seen anything quite like this before, so I'm hoping someone else on here has. Thanks in advance!</p>
  
  <p>PS - Obviously, this needs to be looked at in IE6 for troubleshooting, which I know will be as painful for you as it is for me.</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>After a little more digging on CSS expressions, based on the first answer, I came to a solution that works for fixed positioning the menu to the TOP of the page. All I need is to be able to use this and apply it to the bottom of the page. It's not as simple as switching all "top"s to "bottom"s, so I'm hoping someone can enlighten me. Here's the CSS:</p>
  
  <pre><code>#divfixed { 
      position: absolute; 
      top: expression(0+((e=document.documentElement.scrollTop)?e:document.body.scrollTop)+'px'); 
      left: expression(0+((e=document.documentElement.scrollLeft)?e:document.body.scrollLeft)+'px');}
  </code></pre>