Chapter 20. Automating Dreamweaver

One of Dreamweaver’s greatest selling points is that it makes you more productive. You’ve experienced this firsthand if you’ve ever labored over tables in an HTML text editor. What once took many keystrokes now takes one click of the Insert bar’s Table object.

If you’re looking for even more ways to cut time off your day, Dreamweaver doesn’t disappoint. In addition to its Snippets, Library, and Template features (see Chapter 18 and Chapter 19), the program offers two tools that let you automate common and time-consuming tasks: the History panel and the Find/Replace command.

The History Panel Revisited

As you work on a Web page, Dreamweaver keeps track of everything you do. You can see a list of your actions—your history—in the History panel. Each document has a separate history, which Dreamweaver discards when you close the document or quit the program.

You can use the History panel to quickly undo or redo multiple actions (see Undo, Redo, and the History Panel), but that’s only the tip of the iceberg. You can also use it to replay and record a series of actions you wish to repeat. If you’ve ever used macros in Microsoft Word or actions in Adobe Photoshop, you’ll probably get the hang of this feature quickly.

To open the History panel, choose Window → History, or press Shift+F10 (see Figure 20-1).

The History panel lists every little step you’ve taken while working on the current document—even typos. You can replay one or more actions on the list, copy them for use in another document, or save them as a command in the Commands menu. If Dreamweaver can’t replay an action, such as a mouse click, it appears with a red X next to it (circled). Furthermore, you can’t replay two consecutive steps if you clicked or dragged in the document in between them (you’ll see a solid line in the History list separating such steps). Dreamweaver merely replays the first selected step. The History slider indicates where you are in the document’s history.
Figure 20-1. The History panel lists every little step ...

Get Dreamweaver CS3: The Missing Manual now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.