Results 1 to 4 of 4
  1. #1
    Join Date
    Sep 2011
    Posts
    226
    Plugin Contributions
    0

    Default Fixed Background Image

    Hi

    I want to have a fixed background image that will stick the the border of my site. I want to know how to do this because I have added a background image, which looks like this:

    body {
    margin: 0;
    padding-top: 0px !important;
    font-family: arial, helvetica, sans-serif;
    font-size: 0.72em;
    color: #333333;
    line-height: 17px;
    background: url("../images/Battlefield3text.png") no-repeat 1150px 50px;
    background-position: fixed;

    }

    ... and it works fine on a 4:3 screen, but on a 16:9 or 16:10 screen it does not even view the image.

    The code is still in place on my site:
    pcselect.co.za

    Thank you for your help
    S

  2. #2
    Join Date
    Jun 2005
    Location
    Cumbria, UK
    Posts
    10,266
    Plugin Contributions
    3

    Default Re: Fixed Background Image

    You need to construct your background image to be positioned TOP CENTER in the css.

    If you look at THIS SITE (still in early development) you will see how we achieve what you are after. Look at the BG image, then look at the stylesheet(s).
    20 years a Zencart User

  3. #3
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    Default Re: Fixed Background Image

    Yep I'm trying to do similar. I have a background image which on my 17 inch CRT screen looks fine sticking out about 2 cm each side, which is exactly what I want. However on a wide LCD screen it expands the full width of the screen, which I don't want. I just want the background image to stick out about 2 cm each side of the template, regardless of screen size.

    That http://simplypettags.co.uk/ site looks like the background fixed size image method I want, however I've yet to view it on a wide screen.
    Thanks,
    007

  4. #4
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    Default Re: Fixed Background Image

    That http://simplypettags.co.uk site seems to use a fairly wide image though ( bg.jpg ) , even though it's only 76kb on disk.

    I was hoping there might be a way to specify the number of repeats ( possibly centred ) for a much smaller image.
    Last edited by HeyIts007; 5 Dec 2011 at 02:09 PM.
    Thanks,
    007

 

 

Similar Threads

  1. Background image cover entire background w/one image
    By oxicottin in forum Templates, Stylesheets, Page Layout
    Replies: 43
    Last Post: 3 Apr 2012, 03:18 PM
  2. Fixed background issues.
    By Jordin in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 24 Jul 2009, 07:22 PM
  3. add background image to a attribute then have that background image act as hyperlink
    By sike1234 in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 14 Nov 2008, 05:38 PM
  4. How to Change Background Colour to Background image
    By ittybittykitty in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 9 Aug 2008, 04:36 PM
  5. fixed image size on view large image
    By peterj in forum General Questions
    Replies: 1
    Last Post: 20 Feb 2007, 11:54 PM

Posting Permissions

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