Behavior functions
369
■
The
action
argument is the function call that
applyBehavior()
returns if the action is
added using the Behaviors panel (for example,
"MM_popupMsg('Hello World')")
.
■
The
eventBasedIndex
argument, which is optional, is the position at which this action
should be added. The
eventBasedIndex
argument is a zero-based index; if two actions
already are associated with the specified event, and you specify
eventBasedIndex
as 1,
this action executes between the other two. If you omit this argument, the action is added
after all existing actions for the specified event.
Returns
Nothing.
dom.getBehavior()
Availability
Dreamweaver 3.
Description
Gets the action at the specified position within the specified event. This function acts on the
current selection and is valid only for the active document.
Arguments
event
,
{eventBasedIndex}
■
The
event
argument is the JavaScript event handler through which the action is attached
to the element (for example,
onClick
,
onMouseOver
, or
onLoad
).
■
The
eventBasedIndex
argument, which is optional, is the position of the action to get.
For example, if two actions are associated with the specified event, 0 is first and 1 is
second. If you omit this argument, the function returns all the actions for the specified
event.
Returns
A string that represents the function call (for example,
"MM_swapImage('document.Image1','document.Image1','foo.gif','#933292969950'
)"
) or an array of strings if
eventBasedIndex
is omitted.
dom.reapplyBehaviors()
Availability
Dreamweaver 3.
000_DW_API_Print.book Page 369 Wednesday, July 20, 2005 11:58 AM
Summary of Contents for DREAMWEAVER 8-DREAMWEAVER API
Page 1: ...Dreamweaver API Reference...
Page 16: ......
Page 28: ...28 The File I O API...
Page 38: ...38 The HTTP API...
Page 68: ...68 Flash Integration...
Page 100: ...100 The Database API...
Page 116: ...116 The JavaBeans API...
Page 144: ...144 The Source Control Integration API...
Page 146: ......
Page 254: ...254 Workspace...
Page 298: ...298 Site...
Page 354: ...354 Document...
Page 396: ...396 Page Content...
Page 488: ...488 Design...
Page 550: ...550 Code...