Centralizing background image

Discussion in 'Squirrel WordPress Theme' started by brett_, Feb 6, 2013.

Thread Status:
Not open for further replies.
  1. brett_

    brett_ New Member

    Joined:
    Feb 6, 2013
    Messages:
    7
    Likes Received:
    0
    Hi.. I am using a large image as my background. How do I centralize the image and keep it in a fixed position?
     
  2. Gourav

    Gourav Support Staff

    Joined:
    Oct 19, 2012
    Messages:
    7,728
    Likes Received:
    207
    Paste this code in Custom CSS
    Appearance > Theme Option > Styling Option > Custom CSS

    Code:
    html, body {
      height: auto;
      width: auto;
      background: url(Enter your image address) center center no-repeat;;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
    }
    This will solve your issue.
     
  3. brett_

    brett_ New Member

    Joined:
    Feb 6, 2013
    Messages:
    7
    Likes Received:
    0
    Thank you. This worked perfectly.
     
Thread Status:
Not open for further replies.

Share This Page