Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2005
    Location
    UK, London
    Posts
    762

    <div> isnt staying on the fixed position. Works differently in IE and FireFox :S

    Hello,

    Take a look at this wierd wierd problem. I have a table 1000x1000. Thats it.

    above the table, i have the following <div></div> code

    PHP Code:
    <div style="position:absolute;top:200px;left:200px;width:40px;height:40x;text-align:center">
    <
    a href="http://www.google.com" target="_blank" title="Click here to go to Google">
    <
    img border="0" src="images/banners/black.gif" width="40" height="40"></a></div
    on Internet explorer, it looks like this:
    http://img103.imageshack.us/img103/3366/ie8ts.jpg

    on firefox, it looks like this:
    http://img103.imageshack.us/img103/7701/firefox4sn.jpg

    it should fit perfectly into the grid. but it isnt. What is causing the div to jump to differnt coordinate and how do you get it to stay in once place?

  2. #2
    CSS validator says: Invalid number : height Unknown dimension : 40x

    For more details please go to http://jigsaw.w3.org/css-validator/

  3. #3
    Join Date
    Oct 2004
    Location
    Brisbane, Australia
    Posts
    259
    Looks like you have a typo.

    Try height:40px; and see if that works

  4. #4
    Join Date
    Jan 2005
    Location
    UK, London
    Posts
    762
    it didnt work, so what i did was, created a new page, created a table and put the div stuff on that new page. i called the new page "grid.php" and then on the index.php page, i included it using <iframe></iframe> and it is working accurately now.

    It seems that, my header stuff was casing the div to jump. This iframe method is working. So, thanks for your help guys anyway .

  5. #5
    Check out http://www.quirksmode.org - it has some great resources on CSS and browser incompatibilities.

Posting Permissions

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