SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 1868 | Next

Joseph W. Lowery

"Dreamweaver CS3 Bible"

??? Reserve the
objectTag() function for your intermediate-to-advanced object-creation projects.
TIP TIP
BC 12
Creating and Using Objects
Offering help
As features are added, objects often grow in complexity. An object with multiple parameters??”especially if
it is intended for public release??”could potentially benefit from a Help button. Dreamweaver offers just
such a button to aid custom-object builders and their users.
Including the displayHelp() function causes Dreamweaver to display a Help button, directly beneath
the OK and Cancel buttons found to the right of a user-created parameter form. When selected, this button
calls whatever is defined in the function.
For example, to define a Help button that puts up an informative message within Dreamweaver, you might
code the displayHelp() function this way:
displayHelp() {
alert(???Be sure to name all your layers first???)
}
You??™re not restricted to in-program alerts. If you have a much larger help file, you can display it in your primary
browser by using Dreamweaver??™s built-in browseDocument() function. With the following definition,
when the Help button is selected, Dreamweaver first opens the primary browser (if it??™s not already
running) and then shows the object-specific help file:
displayHelp() { dreamweaver.


Pages:
1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880