Dreamweaver with the popularity of the internet, many people are not satisfied with just surfing the internet, but want to participate in deep. Now, having your own web site has become a trend. Although it's not difficult to make a simple Web page, it's not so easy to make a very refined website, so we have specially prepared a series of tutorials on the latest website design software dreamweaver MX 2004, which I hope will help you.
Usually in a website there will be dozens of or even hundreds of basic similar styles of pages, if each time you reset the page structure and the same section of the navigation bar, all kinds of icons appear to be very troublesome, but we can use the Dreamweaver MX 2004 template features to simplify the operation. In fact, the function of the template is to separate the page layout and content, after the layout is designed to store as a template, so that the same layout of the page can be created through the template, so can greatly improve work efficiency.
first, the production of templates
Make a template and make a common page exactly the same, just do not need to make all parts of the page to complete, just need to make a navigation bar, title bar and other pages of the public part, and the middle area with the content of the page to fill.
Step one: First run the "file→new" command in Dreamweaver MX 2004, then select the "Template page→html Template" option from the window shown in Figure 1, and then click the "Create" button to create a template file.
Step Two: Insert the Web page frame, navigation bar, flash title, and all the public elements of the page in page Design view (Figure 2), and then run the File→save command to save the template.
Tip: You can download a favorite Web page, and then open it in Dreamweaver MX 2004, just keep the frame and other elements after the "File→save as Template" command to save it as a template, so you can save a lot of time to make a template.
In order to avoid editing errors that result in changes in the elements in the template, the contents of the template are not editable by default, and the area can only be changed in the document created by the template if a range or paragraph of text is set to editable. Use the mouse to select an area (that is, the area of each page with different content), then run the modify→templates→new Editable Region command, and set a name for the area in the pop-up dialog box, which completes the editing area.
Tip: After you set up the editing area, you need to run the "file→save" command to save your changes.
Second, the use of templates
Once you have the template, you'll need to use them when you edit the page. Just run the "file→new" command in the Dreamweaver MX 2004 main window to see the new window shown in Figure 1, and then go to the Templates tab to see the saved template and choose one that can also be previewed in the preview area in the right section (Figure 3), Finally select a favorite template and click the lower "Create" button to open this template.
In the open template, the area that cannot be edited is displayed in a highlighted state, but some locations are locked, but not highlighted, mainly because the picture just covers the background color. In this case, you can run the "edit→preferences" command, select "Highlighting" in the pop-up window's "Category" list, and then select the Show option next to "Locked regions" in the right section (Figure 4) and set the highlight color to blue so that you can clearly identify the locked area in the template.
Tip: If you still can't see the highlight effect, you can also select the view→visual aids→invisible Elements command in turn.
Finally, we just add the content of the page in the editable region, such as add some text description or insert the corresponding picture, finally through the "file→save" command to save the page.
Iii. Modifying and replacing templates
After creating a number of pages through a template, if you need to change the page or add columns, and then manually modify all the pages is very cumbersome, so we can use the Dreamweaver MX 2004 template modification function to solve this problem. For example, after we have modified the template, run the "file→save" command to save the template, and then pop-up the prompt box to ask if you want to update all the pages that use the template (Figure 5), after the confirmation will show the total number of updated pages and update the time and other information.
In addition, Dreamweaver MX 2004 also provides a way to replace a template for a Web page, so replacing a template is a bit like changing clothes, as long as you make a variety of templates, and then you want to wear which one to wear. However, the template is not easily replaceable, you can replace the template is the condition that the replacement of the page must be created through the template, and the page can be edited in the number and name of the template to be replaced by the number of editable regions and names consistent. For example, there are 3 editable regions in a Web page named T1, T2, and T3. There is also a template, regardless of the structure of the template, as long as it also has 3 editable regions, and the name is T1, T2, and T3, you can use it to replace the new template for the original page, while the contents of the 3 editable regions in the page will remain unchanged. The specific replacement template method is also very simple, as long as the "windows→templates" command to open the template panel, at this time you can select the appropriate template from the upper area, and then click the Apply to Page button, so you can quickly complete the template replacement operation.
Tip: Use this feature to make two versions of summer and winter for the home page, so you can easily replace the template.
In fact, the relevant content of the template is still a lot, but limited to the length of the selected part of the introduction, I hope you can extrapolate, thoroughly understand the subtlety of the template.
Turn from: Dynamic Network production guide www.knowsky.com