Results 1 to 7 of 7
  1. #1
    Join Date
    Jan 2007
    Posts
    4,664
    Tokens
    1,679

    Latest Awards:

    Default Repeat footer background only staying size of window +REP

    So I have this problem with a footer background where I have put the size 100%. But when the window is smaller than the width of the site (or some screen resolutions) it doesn't repeat when the screen scrolls right. I have the same repeat for a header background which works fine so I have no idea why this is happening.

    +rep to anyone who helps me solve this problem!


  2. #2
    Join Date
    Sep 2009
    Location
    Hull
    Posts
    827
    Tokens
    0

    Latest Awards:

    Default

    make the bg image like 20px x 100px (example) then use background: url('link/to/image.jpg') repeat-x;

    Lew.
    Im not here to be loved, I love to be hated :-}


  3. #3
    Join Date
    Jan 2007
    Posts
    4,664
    Tokens
    1,679

    Latest Awards:

    Default

    Quote Originally Posted by Lewiie15 View Post
    make the bg image like 20px x 100px (example) then use background: url('link/to/image.jpg') repeat-x;

    Lew.
    The bg image is already a thin strip and repeats x, it's a div background if that helps and the div is what I gave the 100% width value to.


  4. #4
    Join Date
    Sep 2009
    Location
    Hull
    Posts
    827
    Tokens
    0

    Latest Awards:

    Default

    Post the css?

    Maybe a little more helpful.

    Thanks, Lew.
    Im not here to be loved, I love to be hated :-}


  5. #5
    Join Date
    Nov 2008
    Location
    Cambridge, UK
    Posts
    901
    Tokens
    100

    Default

    try putting width: 100% into your body and into the html selector
    we're smiling but we're close to tears, even after all these years

  6. #6
    Join Date
    Jan 2007
    Posts
    4,664
    Tokens
    1,679

    Latest Awards:

    Default

    Code:
    .footerbackground {
        background-image:url(../images/footer-repeat_06.png);
     background-repeat:repeat-x;
     width: 100%;
     background-position:bottom;
    }
     
    .footer {
     height: 111px;
     width: 1104px;
     margin-left: auto;
     margin-right: auto;
     
    }
     
    #innerfooter {
        width: 900px;
     height: 100%;
     margin-left: 102px;
     text-align: left;
        text-shadow: 1px 1px 0px #000000;
    }
    Start of the html:

    HTML Code:
    <body><center>
    <div class="sitebackground"><div class="footerbackground">
    So the footer div is inside the other background div, would this be whats causing it? And if it is how can I merge them while keeping the header at the top and footer at the bottom?
    Last edited by Firehorse; 26-10-2010 at 09:51 AM.


  7. #7
    Join Date
    Jan 2007
    Posts
    4,664
    Tokens
    1,679

    Latest Awards:

    Default

    (Slaps self round face)

    Ok I fixed it by adding a min width value. +rep to you guys if I can.


Posting Permissions

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