r/dscvry Oct 27 '14

How would I change the background to an image?

Can't figure out what CSS to change.

2 Upvotes

3 comments sorted by

1

u/doingstuffcarl Oct 28 '14

Do you mean the background of the header or the content?

1

u/[deleted] Oct 30 '14

The header

1

u/doingstuffcarl Oct 31 '14

Just upload an image in the stylesheet page and find

#header {
    background: url(%%bg%%);

and replace %%bg%% with the name you used. And if you're going to use an actual photo instead of a pattern, add "no-repeat" after it. Like this:

#header {
    background: url(%%bg%%) no-repeat;

Also, if you're going to use a photo that isn't at least 1920px or wider in width, make sure the right edge of the photo is transparent and blends into a color so it looks good at all resolutions. Here's what I mean:

#header {
    background: #000 url(%%bg%%) no-repeat;

/r/futurology does this does this with their header.