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 4 of 4
  1. #1
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts

    another css prob, navigation gets pushed up in IE9

    Hey.

    I'm working on a website right now, and it's almost finished. It looks just like i want it to in FF and Safari and all other browsers, but in IE 9 it pushes the whole menu up.

    Screenshot IE9 (assuming its the same in IE 6/7 and 8):



    Screenshot Mozilla FF5:



    Here's da CSS:

    PHP Code:
    #navbar {
        
    backgroundurl(site_images/navbar.gifno-repeat;
        
    width475px;
        
    height34px;
        
    floatright;
        
    margin-right40px; }

    #navigation li {
        
    list-style-typenone;
        
    displayinline;
        
    floatleft;
        
    margin-top: -11px;
        
    padding-right30px; }
        
    #navigation a {
        
    text-decorationnone;
        
    color:#ffffff;
        
    font-size11px; }

    #navigation a:hover {
        
    backgroundurl(site_images/active.gifno-repeat;
        
    text-decorationunderline;
        
    color#079bd4; } 
    A live view: http://79.143.184.10/css2/index.php

    Any1 can help?

  • #2
    New to the CF scene
    Join Date
    Jul 2011
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I also have had a problem, centered elenentur,checked again all the elements.Something somewhere is not specified or is specified multiple times

  • #3
    Senior Coder
    Join Date
    Aug 2006
    Posts
    1,260
    Thanks
    10
    Thanked 277 Times in 276 Posts
    With no doctype, IE will render in quirks mode - very different from standards mode. Put in a doctype, fix your code errors, and see if that solves it.

    Dave

  • #4
    Registered User
    Join Date
    Jun 2011
    Posts
    1,063
    Thanks
    12
    Thanked 241 Times in 240 Posts
    as with a doctype, you need to set a height to your lis.

    Code:
    #navigation li {
     height: 34px;
     line-height: 34px;
    }
    instead of trying to use a negative position relative, using line-height (equal to the height) to center vertically

    ---

    you can view ie7 & ie8 in ie9. its a useful simulator.
    should be tools --> developer tools (or just f12 is you have one).



  •  

    Posting Permissions

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