Mostly we apply so many things in every project, our fingers accept all things during code-behind but sometime I feel really fed-up when I write same things in every project or application. Finally, I have read some snippet tricks that how do people use snippets in projects and how they save time and shows his better performance.
Okay, Lets take a look in below steps and video that how to create a snippet in Adobe Dreamweaver CS5.
Why?
Snippet is use for saving your code into library. Some of code, script or commands we use regularly, snippet save your codes and scripts. (e.g. script tag, functions, core classes). Dreamweaver has built-in snippets (e.g. Javascript regular functions, html codes, textfield functions)
Usage:
Open Window menu and select Snippets (Shift+F9)

Figure 1
In the Snippets window right click and you will find other options.
- New Snippet (This option helps you to create a new snippet)
- New Folder (By creating a folder you can keep you snippet in separate folder)
- Edit (Modify the snippet which had been created by you or Dreamweaver)
- Insert (Double click to add snippet into open document where your pointer is)
- Rename (To rename a snippet)
- Edit Keyboard Shortcuts (Setup a keyboard shortcut to each snippet)

Figure 2
Select the “New Snippet” in the snippet menu and write your tag which you use mostly in the project, in the below figure I created a jQuery Starter + Script Starter snippet for using a <script> tag with the jQuery document.ready method.

Figure 3
After the creating a snippet you can define a Keyboard shortcut. It is a very simple procedure to create a snippet, please check the screencast where I define all the snippet procedures and how will you setup keyboard shortcut.
Thank you for reading! You can comment below to share tips and you can help me to make it better and easiest.
Popularity: 4%





Comments on this entry (4 comments)
Did you like this post? You can share your opinion with us! Simply click here.