Vectorials
Flash Perfection
3D Lessons
Tutorialkit
Markup Tutorials
Learn PHP
network
adv banner
HTML and CSS  Home HTML and CSS Tutorials Advanced CSS (linking to an external style sheet)
rss

Advanced CSS (linking to an external style sheet)

Author: Adam Priestley More by this author


The advanced way, and the easiest way to do CSS is to link to an external style sheet. Here I will sow you how. If you are new to CSS, I reccommend reading the basic CSS tutorial first, if you haven't already.

First, open up notepad and put all your styles in. One of the great things about external style sheets is that you don't have to put in the <style> tags, just the code that normally goes in between them.

image 1

Put all the code in that you want, but it might be best to just start with something like this:

body{font-color:#CCCCCC}

Got that? Go to file-->save as and save the file as style.css It must have the .css extension, otherwise it won't work.

Open up the file that you wish to apply the style to, and put this into the <head> </head> tags of the page:

<link rel="stylesheet" href="style.css">

If you gave your .css file a different name, you will have to change it in the code above.

That is all there is to it!



Rate this Material: Bad 1 2 3 4 5 Excellent
print this page tell a friend subscribe to newsletter subscribe to rss

Add comments to "Advanced CSS (linking to an external style sheet)"