• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Hour 18. Formatting Text with Cascading ... > External Style Sheet Priority

External Style Sheet Priority

What if you choose to incorporate two external style sheets into one document? Depending on its priority, one style will overrule another. For instance, if I applied an external style sheet that states italics are to be red, and then apply another external style sheet that states they should be green, the priority defines who wins the battle.

The rule to follow is that the tag closest to the text “wins.” In other words, if I have an internal and external style sheet, and both define the color of the text, the internal style sheet wins. Why? Because the internal style sheet is actually defined on the page. If I then select the text and change it to another color, that tag will win because the text is right inside of the <font> tag.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint