Snippets are one of the more useful tools in Homesite. They allow you to create small code macros that you can use over and over.
Difficulty: Easy
Time Required: 10 minutes
Here's How:
- Press the F9 button once or twice to make the Resource Tab display.
- In the resource tab, click on the fifth tab - called Snippets. It looks like a document with < and > on top.
- Right click in the new tab window, and choose "Create Folder". Give your folder a name that relates to the snippets you're creating.
- Right click on the new folder, and choose "Add Snippet".
- Give the snippet a descriptive title.
- Type the text that you would like to start the snippet with. Note, where the "start text" ends and the "end text" ends is where your cursor will be placed when the snippet is added.
- Type the text you would like to end the snippet with in the "End Text" box.
- Click OK.
- To add the snippet, place your cursor in your Web document where you would like the new snippet.
- Double click on the snippet title.
Tips:
- Use snippets to contain blocks of text that you use often on your site.
- I created a snippet for every XHTML attribute in the XHTML Element Library.
What You Need:
- Homesite


