HighDots Forums  

Internal vs External stylesheets

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Internal vs External stylesheets in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Stapes
 
Posts: n/a

Default Internal vs External stylesheets - 08-06-2007 , 09:29 AM






Hi

I understand the following is an example using an internal stylesheet.

<style type="text/css" title="currentStyle" media="screen">
@import "main1.css";
</style>

How would I specify it as an external stylesheet?

Stapes


Reply With Quote
  #2  
Old   
Andy Dingley
 
Posts: n/a

Default Re: Internal vs External stylesheets - 08-06-2007 , 10:42 AM






On 6 Aug, 15:29, Stapes <steve.sta... (AT) gmail (DOT) com> wrote:

Quote:
I understand the following is an example using an internal stylesheet.

style type="text/css" title="currentStyle" media="screen"
@import "main1.css";
/style
It's both: an internal stylesheet (inside the <style> element) and an
external stylesheet that's referenced by it (main1.css).

The syntax used here is still valid and will work, but it's an
obsolete trick used to get round some ancient NS4 problems. There's no
reason to continue doing so.
http://www.w3.org/TR/CSS21/cascade.html#at-import


Quote:
How would I specify it as an external stylesheet?
<link type="text/css" rel="stylesheet" href="main1.css" >


Strictly you would convert it to this:
<link type="text/css" rel="stylesheet" href="main1.css" media="screen"
Quote:
(with the media selector)

but unless you have a particular concrete reason for doing this,
you're probably better taking it out and applying the stylesheet to
all media.



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.