0

I'm trying to get my background image to show up only once at the top of the page. When i open live preview (in Brackets) it load correctly, that is, only once. When i reload the page though it repeats as if there was no no-repeat tag used. If I delete a line and put it back the live preview goes back to showing the correct non repeating background but as soon as i hit reload in the preview window it goes back to repeating. please help.

Here is the code:

body {
    background: no-repeat url('/Users/username/Documents/topatopa.jpg') ;
    background-size:120%;
}

I have also tried the forms:

body{
    background: url('/Users/username/Documents/topatopa.jpg') no-repeat;
    background-size 120%;
}

And

body{
    background-image: url('/Users/username/Documents/topatopa.jpg');
    background-size 120%;
    background-repeat: no-repeat;
}

And

body{
    background-repeat: no-repeat
    background-image: url('/Users/username/Documents/topatopa.jpg');
    background-size 120%;
    ;
}

Any ideas???

rainman0915
  • 1
  • 1
  • 1
  • What happens if you actually try it in a browser proper? What happens when you upload it to a server? – BenM Sep 27 '15 at 19:23
  • Use your browsers developer tools to inspect what css is applied. Your CSS is not valid: `background-size 120%;` > `background-size: 120%;` – allcaps Sep 27 '15 at 20:28

0 Answers0