Using the Code Toolbar


Dreamweaver 8 includes a Code toolbar full of conveniences for coding.

1.

In the Design view portion of the training.html page that you are viewing in Split view, place your insertion point within the table and select the <table> tag in the tag selector. On the Code toolbar in the Code view portion of the document, click the Collapse Full Tag toolbar icon.

The Code toolbar enables you to collapse full tags, a selection, or everything outside of the selected tag or selection (by holding down the Alt/Option key). This enables you to close code that you are not working with so that you can view more of the code that you want to work with.

2.

On the Code toolbar, click the Expand All toolbar option.

Dreamweaver never disturbs the code; it only hides portions for easier viewing. You can expand the code at any time.

3.

Place your insertion point within any table row (<tr>) tag. Click the Select Parent Tag button on the Code toolbar.

Dreamweaver selects the parent tagin this case, the <table> tag.

4.

With the <table> tag still selected, click the Apply Comment button on the Code toolbar. From the resulting menu select Apply HTML Comment.

HTML comments are used to make notes in the code, to indicate or explain the use of a particular section of code, or to disable a portion of the document without actually deleting the code. Using the Code toolbar's Apply Comment option makes it quicker to comment out a section of code.

Dreamweaver surrounds the table with the HTML comments tags (<!-- -->), thus removing the table from view while browsing the page.

5.

With the commented <table> tag still selected, click the Remove Comment button on the Code toolbar.

Note

Cascading Style Sheet (CSS) comments are different from standard HTML comments. A CSS comment appears as /*Comment*/ in a style sheet. You can insert CSS comments by selecting Apply /* */ Comment from the menu after clicking the Apply Comment button.


If you select a commented section of code, Dreamweaver will remove the comments surrounding the selection for you.

You can leave the training.html document openyou'll work with it again later in this lesson.

Note

Dreamweaver includes many tools for code editing that give users precise control over the development of code. You can store information on standard and custom tags using the Tag Library Editor. This tool gives you the ability to modify current tags and import new tags into the already extensive database of tags that is integrated in Dreamweaver. Tags are set up in a system of libraries; each library is specific to a different type of code (HTML, CFML, ASP, and so on). You can add or delete libraries. The individual libraries each contain a number of tags for which you can edit the Tag Format: Line Breaks, Contents, and Case. The Preview text field displays the tag according to the options you set. Each tag contains a number of attributes that can be customized as well. Choose Edit > Tag Libraries to open the Tag Library Editor. Use caution when adding, modifying, or deleting tag libraries, tags, and tag attributes. This dialog box is best for advanced Dreamweaver users who have a thorough understanding of the code they want to alter.





Macromedia Dreamweaver 8(c) Training from the Source
Macromedia Dreamweaver 8: Training from the Source
ISBN: 0321336267
EAN: 2147483647
Year: 2006
Pages: 326

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net