PDA

View Full Version : Link a Style Sheet


bluspartan
01-26-2011, 12:37 AM
MY OS: Mac OSX Snow Leopard
Version: Dreamweaver CS5

I created a .css file that I want to link to my index page, however when I right click in the CSS Styles Browser on the upper right hand side, then click "Attach Style Sheet," the "Link" button is not highlighted, therefore not allowing me to link it to an html file. Only the "Import" button works.

How can I link it to my desired HTML file, or what is the alternative method to linking these two together?

Thanks

edbr
01-26-2011, 01:39 AM
not sure why you cant do that but if you opeen code view and add in the <head>
<link rel="stylesheet" media="all" type="text/css" href="style/layout.css" />
it will link , of course edit the path and file name

DWcourse
01-26-2011, 01:44 AM
Attach style sheet is used to attach a style sheet to the currently open html file. It is not used to attach an html file to a style sheet.

edbr
01-26-2011, 01:46 AM
Attach style sheet is used to attach a style sheet to the currently open html file. It is not used to attach an html file to a style sheet.
there you go!

bluspartan
01-26-2011, 02:06 AM
Oh Wow thank you! That really helped. All I had to do was be in the .html file tag and do the same thing.

Thanks again.