The Dreamweaver engineers didn??™t stop with the aforementioned JavaScript APIs; they created additional
APIs for file input/output, source control integration, JavaBean management, design notes, Fireworks integration,
Flash objects, and more. Extending Dreamweaver has basic documentation about them all.
To make the behavior programmer??™s life a little easier, I??™ve included coverage of some of the most often used
API functions. Although the following sections are in no way exhaustive, they do give a good example of
how API functions work in Dreamweaver in general and in behaviors in particular.
The Dreamweaver API functions have a prefix of dreamweaver, dom, or site. The
dreamweaver prefix can also be abbreviated as dw as in dw.getDocumentDOM(). The dom
functions refer to the DOM of a document returned by the getDocumentDOM() function (as explained in
the following section). The site functions refer to selections in the Site panel.
The dreamweaver.getDocumentDOM() function
The getDocumentDOM() function is the starting point for many Dreamweaver JavaScript manipulations.
It returns the entire DOM for the specified document, thus enabling the document to be read and manipulated.
Generally, getDocumentDOM() is used in this fashion:
var theDom = dreamweaver.
Pages:
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924