Page Alignment

Discussion in 'HTML - XHTML - CSS' started by Tad, Jun 28, 2007.

  1. Tad New Member

    Hey

    Does anyone know how to change the alignment of a page? I am working with the Music Shop template which is set to the left. I would like the page in the middle. I have looked at the CCS sheet and the Page HTML code and I can't see where to change this!

    Cheers
    Tad
  2. BoneZ New Member

    I would also like an answer to this. I went to CSS programming sites and tried several different things and still couldn't get my page to align center. Maybe i'm overlooking something or something is overriding my text-align:center lines?
  3. lmfrench New Member

    In the CSS the very first variable is either html { blah; blah; etc;} or body {blah; blah; etc;} whichever it is place the text "margin:auto;" if that doesn't work put "text-align:center" let me know if those do not work...if not you may want to post your CSS here so we can see what the error is.

    :)
  4. BoneZ New Member

    I kept trying the "text-align:center" thing in several different places the other day to no avail. I didn't know about the "margin:auto;". It works perfectly! Thank you for the help. :)
  5. lmfrench New Member

    You are very welcome.
  6. BoneZ New Member

    Ok, so it doesn't work perfectly. In Firefox, the "margin:auto;" looks fine like it should, but in IE, it makes all the tables have spaces in them. That's probably why mimoun made it with "margin: 0px" instead of auto.

    So, i can either have my page centered looking good in Firefox and looking mostly good in IE (except larger spaces between tables), OR, i can have my page aligned to the left (0px) and have both IE and Firefox look perfect.

    Any suggestions Lisa or just live with it? :D
  7. W3Daryl New Member

    I also use a wrapper like id="container" which has the margin: 0 auto;. You might want to look at where you placed your in the CSS. One other thing I always do is have a * { margin: 0; padding: 0; }, then I specify my paddings and margins as need. This way you won't get unexpected results, * is equal to all tags. Cheers.