Dreamweaver MX Templates - Questions and Answers
About editable and locked regions:
A template has two types of regions: editable and locked (non-editable). Editable regions are the sections of a template that have changing content, such as an article in a newsletter. Locked regions are the sections of a template that have static, unchanging content, such as a corporate logo or a standard site navigation bar.
When you edit a template (a .dwt file), you can make changes to both the editable and locked regions. You can also create new editable regions, or lock editable regions. The editable and locked regions are highlighted in the template. By default, editable regions are highlighted in blue and locked regions are highlighted in yellow. You can change the highlight colors in Dreamweaver Highlighting Preferences.
When you edit a document that has a template applied to it (an .htm file), you can make changes to the editable regions only. The locked regions are highlighted, indicating that you cannot change these areas.
Understanding editable and non-editable regions
Issue
Dreamweaver handles updates to editable and non-editable
(locked) regions differently. Changes in the locked
regions will be reflected in the updated pages, while
changes in editable regions will not.
The only time that the template affects the content in the editable region of a template-based page is the first time the page is opened from the template (File > New from Template). After that point it is not possible to update the editable regions of this page globally. Doing so would erase the existing content in the editable region, so Dreamweaver does not allow it. To change this content in the editable region you must make the change in the page itself, rather than in the original template.
Explanation
Content in templates will be either in a locked region
or in an editable region. A locked region contains
content that will always be written to pages based
on the template. This region cannot be selected or
changed in the page itself; it must be changed in the
original template—thus the term "locked" is
applied to non-editable regions. An editable region
contains content that is editable in the pages based
on this template. Due to this fundamental difference,
the two regions work in different ways from one another:
Locked regions
Content in locked regions of a template will be written to all HTML pages based
on this template.
Changes to content in locked regions of a template will prompt an update to
HTML pages that use this template.
Once updated, HTML pages that use this template will show the content changed
in the locked region of the template.
Editable regions
Content in editable regions of a template will only be written to another HTML
page once—when the new page is initially created.
Content in editable regions of a template will not be written when choosing
Modify > Templates > Apply Template to Page. This means that the only
way to write editable content to a page is to choose File > New from Template.
When pages are updated , locked regions will be updated but editable regions
will not.
Examples
The following examples will illustrate these concepts in practical terms:
Changes to editable regions
A user enters the word "Hello" in the editable region of the original
template. After updating the pages from this template, Dreamweaver does not
update the editable regions in these pages. This means that the word "Hello" does
not appear on the pages. This is because the region is editable, which means
the content can be different in each individual page.
Changes to locked regions
A user enters the word "Hello" in a locked (non-editable) region of
the original template. The user updates the pages from the template. After
the update, all pages based on that template will contain the word "Hello" in
the proper non- editable region.
Solution
Make changes to editable regions on individual pages. Make changes to locked regions in the original template itself.
Have more questions? Email Me


