Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder
    Join Date
    May 2008
    Location
    Oxford, UK
    Posts
    422
    Thanks
    14
    Thanked 27 Times in 27 Posts

    Some absolute positioning help

    I'm typically having some problems with IE.

    I have 3 absolutely positioned, draggable divs that sit on the right hand side of a container.

    In Firefox when you resize the window the 3 draggable layers sit in the correct position, 10 pixels from the right of the map container. In IE they dont move with the container and fall off the edge of the screen, prompting the user to have to scroll right to find them again!

    Any ideas how I can fix this?

    Page here
    Stylesheet here

    The map area layer is called 'map' and the 3 draggable layers are called 'dragger', 'draggerRoute', 'draggerLearn'

    Thanks in advance!

  • #2
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,863
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    Not a good solution, but reloading the page on resize makes it OK in IE. So, just add
    Code:
    <script type="text/javascript">
    window.onresize=function(){
    if(document.attachEvent)
    	window.location=window.location;
    }
    </script>
    inside your <head>

    PS: remove width:100%; from #mapTop to align left and right columns inline in IE(6)
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #3
    Regular Coder
    Join Date
    May 2008
    Location
    Oxford, UK
    Posts
    422
    Thanks
    14
    Thanked 27 Times in 27 Posts
    Quote Originally Posted by abduraooft View Post
    Not a good solution, but reloading the page on resize makes it OK in IE. So, just add
    Code:
    <script type="text/javascript">
    window.onresize=function(){
    if(document.attachEvent)
    	window.location=window.location;
    }
    </script>
    inside your <head>

    PS: remove width:100%; from #mapTop to align left and right columns inline in IE(6)
    Reloading isn't really an option as a lot of parameters required are of user input. Would be a bit frustrating if you had made a few choices and then the page suddenly reloaded!

    On a side note, I don't have IE6 handy to test, but removing that 100% also solved another problem I had of a rougue pixel! Thanks. (Also I know that I need to sort out a png fix for IE6, it's on my list!)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •