All Posts by Email, Once a Week

Media Temple logo

CSS-Tricks is brought to you in part by Media Temple, the web hosting that we both use and recommend.

background images

  • # September 26, 2009 at 3:11 pm

    Hi ,
    I would be great if someone could help me out with a little issue I have.
    I am trying to get the background of this page
    to look like this

    As the style sheet are different it is working for one but not the other.

    The page is not showing backgroung to the whole of page but is repeating.

    On the page that is working I put this code into the actual page:
    <div id="deco">

    <div class="hilite"></div>

    <img src="img/water.jpg" alt="" width="1" height="1" />

    not via a style sheet and it works if I do the same with the other page it totally will not work so i have put the image in the style sheet, now I need to get it to cover the whole page.
    This is the code i have used in the style sheet:
    /* @group defaults */

    body {
    margin: 0;
    padding: 0;
    background: url(/img/water.jpg);
    height: 1px;
    width: 1px
    position: absolute;


    /* @group deco */

    #deco {
    height: 100%;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;

    #deco .hilite {
    background: url(../img/bubble-hilite.png) 0 0 no-repeat;
    height: 2660px;
    position: absolute;
    right: 3%;
    top: 5%;
    width: 1800px;
    z-index: 1;


    #deco img {
    display: block;

    height: 100%;
    position: fixed;
    width: 100%;

    /* @endgroup */
    The final thing I might add is that the page I am trying to fix has 2 style sheets.

    Any help would be great thankyou.


    # October 1, 2009 at 2:18 am


    Please try the following steps,
    1. <div id="deco">
    <img height="1" width="1" alt="" src="img/water.jpg"/>
    2. #deco {
    3. #deco img {

    Please try this, if you have any other doubts means,
    please open this site( in the firefox browser,
    Then inspect the site using firebug, you can able to see the css coding and html coding.

    Thanks & Regards

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed