This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Dreamweaver > August 2005 > Prevent Dreamweaver from Editing External Stylesheet





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Prevent Dreamweaver from Editing External Stylesheet
skyeneilson

2005-08-10, 11:20 pm

Hi,

I wasn't entirely sure on what to search for, so I aplogise if this issue has
been covered before.

What I want to know is if it is possible to prevent dreamweaver from editing
my external stylesheets automatically.

If that doesn't really make sense, so here is an example.

I have a class in my external style sheet that ONLY defines the border and
background colour of a box - we'll call it "box" for the time being.

This class is used in many many pages in my website.

In each page however the box needs to have different positioning, visibility,
height and width properties that are set inline.

The problem is that if I don't define these styles in the code by hand, when I
change an attribute (say by using the layers panel), instead of changing the
style inline and for the specific element, it changes the external style sheet.
This can't happen because these changes can't be "global".

So is there any way of stopping this behaviour other than editing the styles
inline first?

Thanks in advance,

Skye

Murray *TMM*

2005-08-11, 7:18 pm

> So is there any way of stopping this behaviour other than editing the
> styles
> inline first?


No. You will have to do this manually, inline.

--
Murray --- ICQ 71997575
Team Macromedia Volunteer for Dreamweaver
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================

"skyeneilson" <webforumsuser@macromedia.com> wrote in message
news:ddebff$r00$1@forums.macromedia.com...
> Hi,
>
> I wasn't entirely sure on what to search for, so I aplogise if this issue
> has
> been covered before.
>
> What I want to know is if it is possible to prevent dreamweaver from
> editing
> my external stylesheets automatically.
>
> If that doesn't really make sense, so here is an example.
>
> I have a class in my external style sheet that ONLY defines the border and
> background colour of a box - we'll call it "box" for the time being.
>
> This class is used in many many pages in my website.
>
> In each page however the box needs to have different positioning,
> visibility,
> height and width properties that are set inline.
>
> The problem is that if I don't define these styles in the code by hand,
> when I
> change an attribute (say by using the layers panel), instead of changing
> the
> style inline and for the specific element, it changes the external style
> sheet.
> This can't happen because these changes can't be "global".
>
> So is there any way of stopping this behaviour other than editing the
> styles
> inline first?
>
> Thanks in advance,
>
> Skye
>



James Shook

2005-08-11, 7:20 pm

Define

..box {
stuff
}

in your external style sheet. Link to it:

<link rel="stylesheet" href="my_styles.css" type="text/css">

Then, tell DW you are going to add a new style. When you see the dialog
that lets you choose where the style will be located choose "This page
only." Define .box again with the page-specific stuff. You should end up
with

<link rel="stylesheet" href="my_styles.css" type="text/css">
<style type="text/css">
<!--
.. box {
different stuff
}
-->
</style>

Since the style on the page comes later than the external file, it will
override anything that is defined in the external file.

--
James M. Shook
http://www.jshook.com
skyeneilson

2005-08-11, 7:22 pm

Hi!

I actually don't mind using the inline styles as well, but I'm working with a
group of designers that I think *will* mind... I'll have to make do I suppose.

Thanks so much for your input. At least now I have a definitive answer (even
if it's not the one I really wanted) I know which direction to move in.

Skye

Murray *TMM*

2005-08-11, 11:22 pm

Good luck!

--
Murray --- ICQ 71997575
Team Macromedia Volunteer for Dreamweaver
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com - Template Triage!
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
==================

"skyeneilson" <webforumsuser@macromedia.com> wrote in message
news:ddgigi$bcu$1@forums.macromedia.com...
> Hi!
>
> I actually don't mind using the inline styles as well, but I'm working
> with a
> group of designers that I think *will* mind... I'll have to make do I
> suppose.
>
> Thanks so much for your input. At least now I have a definitive answer
> (even
> if it's not the one I really wanted) I know which direction to move in.
>
> Skye
>



Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews