Welcome to WebmasterWorld Guest from 54.234.153.186

Forum Moderators: open

Message Too Old, No Replies

Creating CSS Templates in DW4

     

dan_popescu

8:17 pm on Dec 14, 2002 (gmt 0)

10+ Year Member



I've decided to build a website using CSS only no tables. I already know how the pages will look like etc. However, I wanna use a template to save time. I already made one, defined the editable regions (I'm using MD4), but when I try to create a "new from template" page it doesn't work. Namely, the new page doesn't retrieve the styles from the .css external file. The link to the .css file is correct. I don't know what else to do. Anyone?

Thanks,
Dan

andreasfriedrich

8:23 pm on Dec 14, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I guess you need to ask that in the WYSIWYG and Text Code Editors [webmasterworld.com] forum since this is not really about CSS but rather about Dreamweaver.

Andreas

dan_popescu

8:29 pm on Dec 14, 2002 (gmt 0)

10+ Year Member



Thanks for the reply. I'm not sure what the problem is - that's why I asked. I mentioned Dreamweaver because I thought it might help.

caine

12:33 pm on Dec 15, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Can't say i have ever had the problem before

So the code for the external .css file is in place in the template, and of course saved.

Questions,

Have you built a page from the template, and saved it before previewing?
Have you checked that the .css link (and correct) is in the new page?

It sounds like a buggy problem with DM, as far as i am aware their are no restraints on including external files for style control on template files.

DaveAtIFG

2:26 pm on Dec 15, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If you're expecting your styles to appear in DW's DesignView window when using an external sheet, my experience is that they will not. But if your links are correct, they do appear when using Preview A Browser. Internal styles, those imbedded in the HTML on your page, DO appear in the DesignView.

dan_popescu

9:20 pm on Dec 15, 2002 (gmt 0)

10+ Year Member



Thanks guys.

Caine
Yes I did what you said. The link to the external css file is not correct when I save the new template based page - instead of css/file.css it shows templates/css/file.css. I don't know why it does that. However, when I correct the mistake it still don't work. And after I save and close the file and then open it back up - the mistake is still there!

Dan

gypsychild

11:57 am on Dec 16, 2002 (gmt 0)

10+ Year Member



If you're saving your new file in the main root of your site and the external css file is in a templates sub-folder, then templates/css/file.css would be the correct path. As soon as you save a file in a different location from the original, Dreamweaver corrects any changes in file paths automatically.

You didn't say if the styles were showing up in design mode. If they are then apply the template, save the new file first and then try previewing it - as mentioned, the external style sheet won't show up in preview until you save your file.

dan_popescu

11:10 pm on Dec 16, 2002 (gmt 0)

10+ Year Member



Thanks man. Somehow it's fixed.

Dan

 

Featured Threads

Hot Threads This Week

Hot Threads This Month