SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Member
    Join Date
    Aug 2004
    Location
    USA
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    DIV content layer on left side being displayed incorrectly

    On www.danoil.com, the content on the left is being shown to the extreme left, even though I have the following defined:

    Code:
    div#resoureces {
        text-align: center;  
    }
    I use 3 CSS sheets for this, however, the layout.css contains all the layer codes.



    Any help is greatly appreciated, thanks!

  2. #2
    [Biped] LJK's Avatar
    Join Date
    Jun 2004
    Location
    In My Jammies
    Posts
    761
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Link

    Hi -
    This was my result after clicking on your link, above:

    Warning: gethostbyaddr() [function.gethostbyaddr]: Address is not a valid IPv4 or IPv6 address in /home/virtual/site12/fst/var/www/html/control_room/include/cms_api.inc.php on line 431

    Fatal error: Call to a member function on a non-object in /home/virtual/site12/fst/var/www/html/control_room/include/cms_api.inc.php on line 470


    El

  3. #3
    SitePoint Member
    Join Date
    Aug 2004
    Location
    USA
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for letting me know about that. I have fixed it, should work now

  4. #4
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,367
    Mentioned
    180 Post(s)
    Tagged
    6 Thread(s)
    HI,

    text-align:center only centers text (except in ie where it centres nested block level elements alos (in error).

    Compliant browsers use auto on left and right as follows.
    Code:
    div#resources {
     background-color: #F4F4F4;
     border: 1px solid #9D9D9D;
     border-top: 0px none;
     border-bottom: 0px none;
     text-align: center;
     width: 110px;
     margin-left:auto;
     margin-right:auto;
    }
    Paul

  5. #5
    SitePoint Member
    Join Date
    Aug 2004
    Location
    USA
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks a lot Paul, it works

    I only need to bug you once more... do you perhaps know why the image ( http://www.danoil.com/images/top-sidebar.gif ) has a gap below it?

    Thanks!

  6. #6
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,367
    Mentioned
    180 Post(s)
    Tagged
    6 Thread(s)
    Hi,
    I only need to bug you once more... do you perhaps know why the image ( http://www.danoil.com/images/top-sidebar.gif ) has a gap below it?
    Its the default margins on the h3 causing the gap. Use this code:
    Code:
    #resources h3 {margin:0;padding:0}
    Paul

  7. #7
    SitePoint Member
    Join Date
    Aug 2004
    Location
    USA
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for all the help Paul Really appreciated.


Bookmarks

Posting Permissions

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