From the course: HTML: Metadata in the Head

Unlock the full course today

Join today to access over 24,700 courses taught by industry experts.

Specifying style directly

Specifying style directly - HTML Tutorial

From the course: HTML: Metadata in the Head

Specifying style directly

- [Instructor] Another way to include styles in your HTML document is to embed them directly in the head of the document. This method may make styling easier to read or understand. But it also means these styles apply only to this particular webpage. For example, on our homepage, we might want to flip the color scheme. So as you know, this is the same page we've been working with in this course. Right now, we have an all white content section here on our homepage. Maybe we'd like to flip that. Maybe we'd like to have this white displaying only on the inside pages. And there are probably several of those. But for this homepage, let's have a blue background in the middle instead. So we just want to recolor just the homepage, for example. So one way that we might go about doing that, and there are several ways to solve this particular issue, but let's just say that we'd like to just go on ahead and install some styles here to the head of our homepage document only where they will take…

Contents