2. Enter a name to be displayed in the Snippets panel in the Name field.
3. If you like, you can enter a brief description of the snippet in the Description field.
4. Choose the type of Snippet you??™re creating: Wrap Selection or Insert Block. The dialog box
changes depending on your choice.
5. If you chose Wrap Selection, enter the code to appear prior to the selection in the Insert Before
field, and the code to appear after in the Insert After field.
6. If you chose Insert Block, enter the code in the Insert Code field. If you switch from Wrap
Selection to Insert Block, Dreamweaver appends the Insert Before field with the contents of the
Insert After field.
7. Choose how you would like the snippet to be displayed in the preview area of the Snippets panel,
rendered in Design view or as code.
If you choose the Design preview option for code that does not display in a browser, such as a
JavaScript function, it won??™t be as readable. You still see the code in the preview area, but it
does not appear in a monospace font, and all whitespace formatting (such as tabs) appears to be lost.
8. Click OK when you??™re finished.
You??™ll remember that when hand-coding, the last 10 used snippets are available directly from the Coding
toolbar??™s Recent Snippets command.
Pages:
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429