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

Lesson 4. Applying Styles > @import Styles

@import Styles

Header and external style sheets also can import other style sheets using the @import rule as shown in Listing 4.6. The @import rule must be placed before all other rules in the header or external style sheet.

Listing 4.6. CSS Code Containing an Imported Style Sheet

@import "advanced.css";

p
{
    font-family: arial, helvetica, sans-serif;
    margin: 1em;
    padding: 1em;
    background-color: gray;
    width: 10em;
}


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


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