Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

Css footer div question...

  • 17-08-2011 09:18PM
    #1
    Registered Users, Registered Users 2 Posts: 4,307 ✭✭✭


    Just trying to create a 100% width footer with a 1000px div centered inside of it

    I'm sure its something very simple that I just havn't figured yet, done a few searches and get seem to get it going... any ideas!?

    Here's an example of what im trying to go for at the bottom of this page - http://www.dimarzio.com/ :pac:


Comments

  • Registered Users, Registered Users 2 Posts: 8,070 ✭✭✭Placebo


    just have margin left/right auto

    [PHP]<div class="footer">

    </div>


    .footer
    {
    margin-left:atuo;
    margin-right:atuo;
    width:960px; //strictly speaking, max width here should be 960px so it fits all resolutions
    }[/PHP]


  • Registered Users, Registered Users 2 Posts: 4,307 ✭✭✭-=al=-


    Yeah it tried it all, but still think its off my 10 px!

    http://student7.bigwavemediahosting.com/electrical/

    there's what i have in the link, just starting a template for en electrical site seems to be ok!


  • Registered Users, Registered Users 2 Posts: 9,383 ✭✭✭S.M.B.


    The 10px padding on the wrapperbg div is causing you the misalignment issue. With all the nested divs and different widths it's hard to figure out exactly what you want.


  • Registered Users, Registered Users 2 Posts: 10,240 ✭✭✭✭Fanny Cradock


    -=al=- wrote: »
    Yeah it tried it all, but still think its off my 10 px!

    http://student7.bigwavemediahosting.com/electrical/

    there's what i have in the link, just starting a template for en electrical site seems to be ok!

    Big Wave Media, eh? Just get Keith to help you out!


  • Registered Users, Registered Users 2 Posts: 125 ✭✭ivanc


    Is your footer div outside your wrapper div? If so you could put it inside the wrapper and mark it up as 100%. Or, if you want to keep it outside, mark it up to the same width, auto margins, etc as your wrapper.

    You might want to mark up your closing divs <!-- end wrapper--> etc which will allow you to easily see which closing div is which.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 4,307 ✭✭✭-=al=-


    Yeah was outside the wrapper, but i shoved the bad boy back in the wrapper and made the items a list... look better, thx :)

    and i finished up in big wave bout a month ago! :pac:


Advertisement