JustRob Posted April 7, 2013 Share Posted April 7, 2013 Hello, I'm trying to build a stylesheet, and am currently working on the background.Right now my background consists of three elements: A background color and image that doesn't repeat, specified in the body CSS. Then there's another background image specified in a separate div, which is placed inside the body tags in my HTML. This second background image repeats vertically. However, this second background image leaves some empty space between it and the right edge of the screen. I want to remove that space so it lines up with the top image. Here's a picture of what's wrong: And here's my CSS so far: @charset "UTF-8";/* CSS Document */body{background-color: #132309;background-image: url(../img/top_right.png);background-position: 100% 0%;background-repeat: no-repeat;}#backgroundright{background-image: url(../img/rightbg.png);background-position: right;background-repeat: repeat-y;margin-top: 199px;height: 500px;} Link to comment Share on other sites More sharing options...
Ingolme Posted April 7, 2013 Share Posted April 7, 2013 The <body> probably has default padding. Use CSS to set it to 0. html, body { margin: 0; padding: 0;} Link to comment Share on other sites More sharing options...
JustRob Posted April 7, 2013 Author Share Posted April 7, 2013 The <body> probably has default padding. Use CSS to set it to 0.html, body { margin: 0; padding: 0;} Yup, that works! Thank you Link to comment Share on other sites More sharing options...
JustRob Posted April 7, 2013 Author Share Posted April 7, 2013 (edited) Nevermind sorry Edited April 7, 2013 by JustRob Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now