WordPress.org

Forums

Background Image (6 posts)

  1. skeletzee
    Member
    Posted 3 years ago #

    Hi all, I am trying to spread the image as a full screen background across my site, fixed with no scrolling, and full screen with no distort across all platforms and screen size, i tried to input the following code with reference from searching online, and although it did make the background appear, not the full image was shown and it repeated to make up the whole screen. This is not the result i want. I am not good in coding. Can someone pls help me?

    #ff_background {
    background: url('images/Trial 1.jpg');

    /* Set rules to fill background */
    min-height: 100%;
    min-width: 100%;

    /* Set up proportionate scaling */
    width: 100%;
    height: auto;
    /*repeat: none;*/

    /* Set up positioning */
    position: fixed;
    top: 0;
    left: 0;
    }

  2. t_virus
    Member
    Posted 3 years ago #

    Remove the /* Set up positioning */ part and use this instead

    #ff_background {
    background-image:url('images/Trial 1.jpg');
    background-repeat:no-repeat;}
  3. skeletzee
    Member
    Posted 3 years ago #

    Hi t_virus, thanks for the reply, i thought no one would help me.

    I tried your method and the image did not repeat, however it is still not full screen and my image still have some at the bottom that is cut off.

    Can advise me pls?

  4. t_virus
    Member
    Posted 3 years ago #

    i guess your image is not big enough for the screen (height)
    either use a bigger resolution image or use this code **i have not tested this yet, please tell me if it works

    #ff_background {
    background-image:url('images/Trial 1.jpg');
    position:fixed;
    top:0; left:0;
    width:100%;
    height:100%;
    background-repeat:no-repeat;}
  5. skeletzee
    Member
    Posted 3 years ago #

    hi, I had tried that code, and also /* */ out the rest of my ff_background code, the image remains the same. : (

  6. skeletzee
    Member
    Posted 3 years ago #

    you mentioned that my image is not big enough, any advice on what my image dimension should be then?

Topic Closed

This topic has been closed to new replies.

About this Topic