>   <link href="basic_style.css" rel="stylesheet" type="text/css">
>
>   <style type="text/css">
> @import url(advanced_style.css);
>   </style>
>
> Make sure you place the "@import url(advanced_style.css)" second, because
> what you're doing is redefining the style rules for compliant browsers,
> which were first set in "basic_style.css".


an alternative is not to override (redefine), but split the styles into
reliable and iffy parts

then you can put the @import into the linked stylesheet (provided it's the
first line)

for example, the linked sheet "basic_style.css" would contain

  @import url(advanced_style.css);
  body { font-family: Verdana, Geneva, Arial, Helvetica, sans-serif ;
       background-color: #EEEEEE;    color: #333333;  }

and then the imported sheet "advanced_style.css" would contain

 body {  margin: 5px 5% 5px 5% ;   padding: 5px 5% 5px 5% ; }

i suppose, perry, this is perhaps what you mean by "redefine"

i prefer to think of it as "adding" the iffy parts and the reliable parts
together

only browsers that understand @import will get the margin and padding
definitions, while all browsers will get the font and colours

so there isn't anything really being "redefined" although both stylesheets
have a style definition for BODY, if that's what you meant

note that @imported styles come first, because some old version of IE has to
have the @import as the first line of the linked stylesheet -- but the order
doesn't really matter, because we've split the style definitions into
mutually exclusive parts

the bottom line is, there's only one line, the <link> tag, in your html


rudy


____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] 
       Send Your Posts To: [EMAIL PROTECTED]
To change subscription settings to the wdvltalk digest version:
    http://wdvl.internet.com/WDVL/Forum/#sub

________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]

Reply via email to