Saving Code Blocks As Snippets - MACROMEDIA COLDFUSION STUDIO 4.5-USING COLDFUSION STUDIO Use Manual

For windows 95/98/nt4/2000
Table of Contents

Advertisement

Writing Code and Web Content

Saving Code Blocks as Snippets

With Code Snippets, you can easily store code blocks and content for reuse. Comment
your snippets just as you would any code block.
To create a code snippet:
1. Click the Snippets tab in the Resources window.
Before adding a snippet, you need to create a folder.
2. Right-click in the Snippets panel and select Create Folder from the shortcut menu.
3. Enter a name for the folder.
4. Right-click in the Snippets pane and select Add Snippet to open the Snippet dialog
box.
5. Enter a name for the snippet in the Description box. Note that snippet names
cannot contain characters that are illegal in file names, such as slashes, special
characters, or double quotes.
6. In the Start Text window, type or paste an opening code block. You can set a default
spacing between the blocks by pressing the Enter key at the end of the start text and
at the beginning of the end text.
7. In the End Text window, enter a closing code block.
8. Click OK.
Right-click a snippet to edit or delete it.
You can create additional folders as needed. The default location for snippets is the
\UserData\Snippets folder below your root directory.
Tip
To insert a snippet, double-click an entry in the Snippets panel or right-click and select
Insert into document from the menu.
Use the snippets shortcut menus to manage snippets and snippet folders.
Because snippets can be created as start and end blocks, you can use
them to surround other tags and content. This is handy for inserting
special formatting, navigation elements, and script blocks. Simply
highlight the content you want to surround, then insert the snippet.
59

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the COLDFUSION STUDIO 4.5-USING COLDFUSION STUDIO and is the answer not in the manual?

This manual is also suitable for:

Coldfusion studio 4.5

Table of Contents