Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

An embedded stylesheet is when you place the styles in the actual page that uses them and not in an external stylesheet. Why would you do this?

0
Posted

An embedded stylesheet is when you place the styles in the actual page that uses them and not in an external stylesheet. Why would you do this?

0

Well one reason is that you only have one page in your website so there’s no point in having an external stylesheet as well. A more common reason is that you have a few styles that only apply to the page in question and are not used anywhere else in the site. You can still have your external stylesheet but just a few very specific styles embedded in the page that the current page needs. Be aware that the more styles you embed then the harder it will be to control the layout and style of the whole site by just changing the stylesheet. Inline Styles : An inline style is where you place the style directly in the html in the tag it refers to rather than specifying a class or ID. e.g.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123