Skip navigation.
Home

Dreamweaver Killer Tips Page 3

UltraQuick Intro to the Server Behavior Builder

note: I plan to add screenshots or a captivate file to give you a realtime demonstration.

This is only an UltraQuick intro to give you just the slightest hint of what’s possible

F1 Help, search for Custom Server Behaviors
1. Read “Using the Server Behavior Builder”
2. Build your first Server Behavior
3. Read “About Custom Server Behaviors”

How to Build a Custom Server Behavior

1. Choose the Document Type: ColdFusion
2. Enter a (file) Name: My First Server Behavior
3. Click OK

How to Build a Custom Server Behavior

New Server Behavior Requirements
– With a dynamic document open, choose Window> Server Behaviors to display the Server
Behaviors panel
– If (+) is disabled, follow all steps (which vary depending on the current server model) listed in the
Server Behaviors panel except the last step
- Click the (+)
- Click OK on the Create a New Code Block dialog
- Click the (+) button and choose New Server Behavior
Add the following code to the Code block field:
<title>Untitled</title>
-Select the word Untitled

- Click the Insert Parameter in Code Block… button

- Complete the dialog that appears (by entering
Page Title as the value) and then Click OK

-Complete the remainder of the dialog:
– Insert code: Relative to a Specific Tag
– Tag: title
– Relative position: Replace the Tag
– Identifier: checked
- Click the Advanced button
– Server behavior title:
Page Title (@@Page Title@@)
– Code block to select:
My First Server Behav_block1
- Click Next…

§ For each Parameter, select the type of field that will display in the custom
server behavior’s dialog by clicking in the Display As column and choosing
the appropriate menu item

§ Click OK

§ Click the (+) button in the Server Behaviors panel and choose Page Title

§ Use the Server behavior just like you would any other:
Complete the dialog, click OK.

- You will see the following code in the Code block
field: <title>@@Page Title@@</title>