Editing and modifying server behaviors
You can edit any server behavior created with the Server Behavior Builder, including server behaviors you download from the Macromedia Exchange website, and other third-party developers.
If you apply a server behavior to a page and then edit the behavior in Dreamweaver, instances of the old behavior will no longer appear in the Server Behaviors panel. The Server Behaviors panel searches the page for code that matches the code of known server behaviors. If the code of a server behavior known to the panel changes, the panel will no longer recognize earlier versions of the behavior on that page.
If you want both the old and new versions of the behavior to appear in the panel:
- Click the Plus (+) button on the Server Behaviors panel (Window > Server Behaviors), select New Server Behavior, and create a copy of the old server behavior.
To edit the code of a server behavior created with the Server Behavior Builder:
- In the Server Behaviors panel (Window > Server Behaviors), click the Plus (+) button and select Edit Server Behaviors from the pop-up menu.
The Edit Server Behaviors dialog box appears, displaying all the behaviors for the current server technology.
- Select the server behavior and click Edit.
The Server Behavior Builder dialog box appears.
- Select the appropriate code block and modify the code to be inserted in pages.
- (Optional) You can change or add parameter markers to the code.
For instructions, see Creating a dialog box for a custom server behavior.
- (Optional) If you want, change where the code block is inserted in the pages HTML code by choosing another option in the Insert Code pop-up menu.
For instructions, see Positioning code blocks.
- If the modified code does not contain any designer-supplied parameters, click OK.
Dreamweaver regenerates the server behavior without a dialog box. The new server behavior appears in the Plus (+) pop-up menu of the Server Behaviors panel.
- If the modified code does contain designer-supplied parameters, click Next.
Dreamweaver asks you whether you want to create a new dialog box, overwriting the old one. Make your changes and click OK.
Dreamweaver saves all changes in the server behaviors EDML file.