View Full Version : CSS not applying to editable region in Template

07-06-2005, 04:59 PM
I have searched the net for help on this before posting.

I'm new to Dreamweaver but not completely new to webwork. I have DW MX2004.

I've made a template which has left and right navigation menus. Central is the editable area. I've made a stylesheet too which doesn't seem to be controlling any text I put in the editable area.

When I make changes to font face and colour it alters but any change in size or alignment isn't reflected in the editable area, even when I preview in IE and FF.

It changes all of that in the nav menus which are part of the template though.

Why would a style sheet affect face and colour but not size, weight or alignment in the editable area.

Here's the body settings in my style sheet.

body {
background-image: url(../images/background_cream.jpg);
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
font-family: Verdana, Arial, Helvetica, sans-serif;
color: #000000;
text-align: left;
font-size: 0.8em;
font-weight: normal;
font-style: normal;

Any help gratefully received.

07-06-2005, 06:02 PM
Hi Elly,
Can you post your whole stylesheet and HTML, or URL to this page online?
My guess is that there's either other style that is given priority, or the structure of your HTML does this.

07-07-2005, 02:39 PM
Hi domedia,

I've saved my css to a .txt file here

http://newsite.worldofwar.net/templatecss.txt ('http://newsite.worldofwar.net/templatecss.txt')

and my template his here

http://newsite.worldofwar.net/Templates/content.dwt ('http://newsite.worldofwar.net/Templates/content.dwt')

and one of the pages made with the template.

http://newsite.worldofwar.net/pressdesk ('http://newsite.worldofwar.net/pressdesk')


07-07-2005, 05:39 PM
The problem has been resolved and I wanted to update the solution here (in case anyone else comes across this).

The suggestion I was given was

Yes - since you are using a) a page with an incomplete doctype, and B ) tables to position your content, your CSS rules for body are not properly inheriting into the table cell containing your main body content. You can change this two ways -

1. Change this -

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

to this -

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"


2. Change this -

body {

to this -

body, td {

As you can see, it has nothing to do with templates.....

I used the first suggestion as the second took away the tiled backgrounds in my cells (td).

I have no idea how that bit of text

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"

fixed the problem, just glad I got passed it. :)

07-07-2005, 07:32 PM
That's good news Elly!
I'm happy you got it sorted out and left the solution here in case other members face the same problem :)