PDA

View Full Version : Rules being added automatically???


AlexC
12-25-2010, 02:06 AM
When i create new styles, Dw automatically adds an additional internal style that shows up in the rules pane. For example:


<style>

.style6
.style7
.style8

...etc.

When I created the style #nav , Dw created .style7 Furthermore, .style7 over rides any styles I determine through #nav

I'm confused why this is happening...? help please.
CS3 on Mac.

Thanks.

Corrosive
12-25-2010, 08:49 AM
Those styles are usually created by highlighting text and changing font weight or colour or something in the properties panel. DW just gives them a sequential style name and puts them in the head tags. Clean them out if you don't want them and recode the CSS and HTML.

AlexC
12-25-2010, 10:10 PM
Thanks!!!!

DWcourse
12-26-2010, 03:08 AM
CS3 will automatically create and name style rules if you make CSS-related style changes in Properties palette. It's very annoying. In CS4+ you are prompted to name the style yourself if you create one this way. The simplest option is to create and name new styles yourself as they are needed and edit the through the CSS rule definition dialog (open by double clicking the rule in the CSS Styles palette).

AlexC
12-26-2010, 06:23 PM
Yes, this is very annoying. Thanks for the clue!

Now my controls are way spread out and inefficient. I don't think I'll be using the properties pane much anymore.

How do I now condense my css rules? Since I've made a few changes to text in one div, the one containing the link to my home page, I now have 3 css styles, or rules, to edit the content in that one div. I want all those controls to be in one rule, #home.

Any ideas on condensing these?

AlexC
12-26-2010, 06:33 PM
also... This is mostly a problem because the style I created for a certain div, #home for example, doesn't any longer control the feature within it that I changed using the properties panel (and consequently got the new style for).

DWcourse
12-26-2010, 06:43 PM
It might actually be easier to note the rules you need and just delete and start over but, if you want to work in the code, you can just cut and pste the properties from the DW created style1, etc. to the rules where they belong.