r/HTML • • Oct 08 '26

help with backgrounds

Not remotely a cs person, for some godforsaken reason my Library Science degree is making me take an html class. I've onto a part where we're working with html and css. I can't figure out how to change the background color of a page. I assume you have to use some version of the {background-color: ____; }, but I can't figure out what element to attach it to. I've tried using body {background-color: ____; }, *{background-color: ____; }, and even making a div around the body, and none of them have worked

0 Upvotes

14 comments sorted by

View all comments

Show parent comment

1

u/TrainingQuantity3744 Oct 08 '26

it works for the text colors, yeah. I am having a weird issue with the stylesheet. When I open it from my computer it appears connected, but when I open the link from where I uploaded it to my school's server, none of the css shows up

1

u/shaunbev Oct 08 '26

Is your HTML linking to a CSS file stored locally, or did you upload the CSS file to the schools server too?

1

u/TrainingQuantity3744 Oct 08 '26

css file and image files all uploaded to the school server