Editing HTML in Dreamweaver > Inserting comments

 

Inserting comments

A comment is descriptive text that you insert in the HTML code to explain the code or provide other information. The comment appears only in the Code view (or Code inspector), and will not display in your Web page in the browser.

To insert a comment:

1 Place the insertion point where you want the comment, either in the Code view (or Code inspector) or Design view.
See Using the Code view (or Code inspector).
2 Click the Comment button in the Invisibles category of the Objects panel, or choose Insert > Invisible Tags > Comment.

Creating a comment generates the following HTML code:

<!-- Comment text-->

To display comment markers in the Design view, choose View > Visual Aids > Invisible Elements. Make sure that comments are selected in the Invisible Elements preferences, or the comment marker will not appear. For more information, see Invisible Elements preferences.

To add to an existing comment, do one of the following:

Select the Comments marker in the Design view and enter text in the Property inspector.
Find the comment in the code (see earlier example) and add text directly to it.