Link to home
Start Free TrialLog in
Avatar of pinaldave
pinaldaveFlag for India

asked on

position fixed does not work in IE

Hello Experts,


<style type="text/css">
.box1 {
position: fixed;
left: 1em;
top: 1em;
border: 3px solid black;
padding: .5em;
width: 8em;
text-align: center;
font-weight: bold;
font-size: large;
background: red;
color: white}



<div class="box1">This is a box positioned at a fixed position and should not scroll</div>
ASKER CERTIFIED SOLUTION
Avatar of GrandSchtroumpf
GrandSchtroumpf

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pinaldave

ASKER

Thank you Grand.
I did not know that.
Trevorhart.. .thanks for answer.
Actually I am preparing the CSS tutorial so I will mentioned this as a drawback. I will not need the javascript for today. Thank you for offer.
Regards,
---Pinal
Avatar of GrandSchtroumpf
GrandSchtroumpf

You don't always need javascript to mimic it in IE.
It can be done with css only in some cases.  The result is not that bad, but it's very ugggggly code that is likely to break, so it should be avoided:  http://www.serger.biz/ee/FixedMenu/FixedMenu.html

And using javascript should definitely be avoided.

The best thing is to use "position:fixed" and use a workable non-fixed alternate solution for bad browsers.
You can always have a little message that tells your visitors to use a good browser if they want to enjoy the site's complete functionality.