background image

326

Document

Arguments

inStr

The 

inStr

 argument is the string to decode.

Returns

A string that contains the decoded URL.

Example 

The following example calls 

dw.doURLDecoding()

 to decode the special characters in its 

argument and store the resulting string in 

outstr

:

outStr = dreamweaver.doURLDecoding(“http://maps.yahoo.com/py/

ddResults.py?Pyt=Tmap&tarname=&tardesc=&newname=&newdesc=&newHash=&newTH
ash=&newSts=&newTSts=&tlt=&tln=&slt=&sln=&newFL=Use+Below&newadd
r=2000+SRd&newcsz=Park%2C+CA&newcountry=us&newTFL=Use+Add
ress+Below&newtaddr=500+El+Camino&newtcsz=Santa+Clara%2C+CA&newtcountry=
us&Submit=Get+Directions”)

dreamweaver.getElementRef()

Availability

Dreamweaver 2.

Description

Gets the Netscape Navigator or Internet Explorer object reference for a specific tag object in 
the DOM tree.

Arguments

NSorIE

tagObject

The 

NSorIE

 argument must be either 

"NS 4.0"

 or 

"IE 4.0"

. The DOM and rules for 

nested references differ in Netscape Navigator 4.0 and Internet Explorer 4.0. This 
argument specifies for which browser to return a valid reference.

The 

tagObject

 argument is a tag object in the DOM tree.

Returns

A string that represents a valid JavaScript reference to the object, such as 

document.layers['myLayer']

. The string is subject to the following conditions:

Dreamweaver returns correct references for Internet Explorer for 

A

AREA

APPLET

EMBED

DIV

SPAN

INPUT

SELECT

OPTION

TEXTAREA

OBJECT

, and 

IMG

 tags. 

000_DW_API_Print.book  Page 326  Wednesday, July 20, 2005  11:58 AM

Summary of Contents for DREAMWEAVER 8-DREAMWEAVER API

Page 1: ...Dreamweaver API Reference...

Page 2: ...epts any responsibility for the content on those third party sites Opera browser Copyright 1995 2002 Opera Software ASA and its suppliers All rights reserved Copyright 2005 Macromedia Inc All rights r...

Page 3: ...r 1 The File I O API 17 Accessing configuration folders 17 The File I O API 17 Chapter 2 The HTTP API 29 How the HTTP API works 29 The HTTP API 30 Chapter 3 The Design Notes API 39 How Design Notes wo...

Page 4: ...117 How source control integration with Dreamweaver works 118 Adding source control system functionality 118 The Source Control Integration API required functions 119 The Source Control Integration AP...

Page 5: ...ns 355 Behavior functions 368 Clipboard functions 379 Library and template functions 384 Snippets panel functions 391 Chapter 15 Dynamic Documents 397 Server Components functions 397 Data source funct...

Page 6: ...e functions 489 Find replace functions 494 General editing functions 500 Print function 520 Quick Tag Editor functions 521 Code view functions 524 Tag editor and tag library functions 544 Chapter 18 E...

Page 7: ...h Objects API which lets you build objects that create Macromedia Flash content The Database API which lets you access information stored in databases and manage database connections The Database Conn...

Page 8: ...an use those APIs to add objects menus floating panels or other features to the product Extending Dreamweaver also explains how to customize Dreamweaver by editing and adding tags to various HTML and...

Page 9: ...andSelectedCodeFragments on page 245 dreamweaver htmlInspector collapseFullTag on page 245 dreamweaver htmlInspector collapseSelectedCodeFragment on page 246 dreamweaver htmlInspector collapseSelected...

Page 10: ...og markSynced on page 262 site compareFiles on page 267 site getAppURLPrefixForSite on page 274 site getSiteURLPrefix on page 280 site serverActivity on page 290 site siteRelativeToLocalPath on page 2...

Page 11: ...alette applySelectedStyle on page 428 added new argument dreamweaver cssStylePalette deleteSelectedStyle on page 429 added new argument dreamweaver cssStylePalette duplicateSelectedStyle on page 430 a...

Page 12: ...age 465 dreamweaver fitSelection on page 465 dreamweaver fitWidth on page 466 dreamweaver zoomIn on page 466 dreamweaver zoomOut on page 467 Guide dom clearGuides on page 468 dom createHorizontalGuide...

Page 13: ...canEditSelectedStyleInCodeview on page 577 dreamweaver cssStylePalette canRenameSelectedStyle on page 578 dreamweaver siteSyncDialog canCompare on page 582 dreamweaver siteSyncDialog canMarkDelete on...

Page 14: ...s in this book s format what is otherwise a continuous line of code must be split When copying the lines of code eliminate the continuation symbol and type the lines as one line Curly braces that surr...

Page 15: ...new database connection types access JavaBeans fscomponents and integrate Dreamweaver with various source control systems Chapter 1 The File I O API 17 Chapter 2 The HTTP API 29 Chapter 3 The Design N...

Page 16: ......

Page 17: ...platforms users have their own copies of configuration files Whenever Dreamweaver writes to a configuration file Dreamweaver writes it to the user s Configuration folder Similarly when Dreamweaver re...

Page 18: ...e copy succeeds false otherwise Example The following code copies a file called myconfig cfg to myconfig_backup cfg var fileURL file c Config myconfig cfg var newURL file c Config myconfig_backup cfg...

Page 19: ...ability Dreamweaver 2 Description This function tests for the existence of the specified file Arguments fileURL The fileURL argument which is expressed as a file URL is the requested file Returns A Bo...

Page 20: ...n the string represent the attributes R is read only D is folder H is hidden S is system file or folder Example The following code gets the attributes of the mydata txt file and displays an alert box...

Page 21: ...er var file1 file c temp file1 txt var file2 file c temp file2 txt var time1 DWfile getModificationDate file1 var time2 DWfile getModificationDate file2 if time1 time2 alert file1 and file2 were saved...

Page 22: ...ast modified on time2 DWfile getCreationDateObj Availability Dreamweaver MX Description This function gets the JavaScript object that represents the time when the file was created Arguments fileURL Th...

Page 23: ...URL The fileURL argument which is expressed as a file URL is the file for which you are checking the size Returns An integer that represents the actual size in bytes of the specified file DWfile listF...

Page 24: ...r list DWfile listFolder folderURL fileMask files if list alert folderURL contains list join n DWfile read Availability Dreamweaver 2 Description This function reads the contents of the specified file...

Page 25: ...etAttributes function to determine whether the file is read only and the confirm function to display a Yes No dialog box to the user function deleteFile var delAnyway false var selIndex document theFo...

Page 26: ...e file is set as writable W You should not use H and V together because they are also mutually exclusive If you combine them H becomes meaningless and the file is set as visible V If you specify H or...

Page 27: ...he string is successfully written to the file false otherwise Example The following code attempts to write the string xxx to the mydata txt file and displays an alert message if the write operation su...

Page 28: ...28 The File I O API...

Page 29: ...on and the port number to the URL as shown in the following example MMHttp getText http www myserver com 8025 For functions that return an object the object has two properties statusCode and data The...

Page 30: ...ServerScripts folder is located in Configuration Connections Scripts server model _mmDBScripts folder Arguments serverScriptsfolder The serverScriptsfolder argument is a string that names a particular...

Page 31: ...es on Shutdown title head body onLoad MMHttp clearTemp body html MMHttp getFile Description This function gets the file at the specified URL and saves it in the Configuration Temp folder which is loca...

Page 32: ...box Returns An object that represents the reply from the server The data property of this object is a string that contains the location where the file is saved which is expressed as a file URL Normal...

Page 33: ...index html file in the People folder inside the www dreamcentral com folder Arguments callbackFunction URL prompt saveURL titleBarLabel The callbackFunction argument is the name of the JavaScript fun...

Page 34: ...pecified URL Arguments URL serverScriptsFolder The URL argument is an absolute URL on a web server If http is omitted from the URL Dreamweaver assumes HTTP protocol The serverScriptsFolder argument is...

Page 35: ...it in the statusCode property of the returned object MMHttp postText Availability Dreamweaver UltraDev 4 enhanced in Dreamweaver MX Description Performs an HTTP post of the specified data to the speci...

Page 36: ...on DeployScripts When Dreamweaver executes this function call the following sequence occurs 1 The myScripts cfm file in the Configuration DeployScripts folder on the local computer is copied to anothe...

Page 37: ...866 specification available at www faqs org rfcs rfc1866 html The contentType argument which is optional is the content type of the data to be posted If omitted this argument defaults to application x...

Page 38: ...38 The HTTP API...

Page 39: ...d independently even if Dreamweaver is not installed For more information about using the Design Notes feature from within Dreamweaver see Using Dreamweaver How Design Notes work Each Design Notes fil...

Page 40: ...lose Description This function closes the specified Design Notes file and saves any changes If all the key value pairs are removed Dreamweaver deletes the Design Notes file If it is the last Design No...

Page 41: ...ied Design Notes file Arguments fileHandle keyName The fileHandle argument is the file handle that MMNotes open returns The keyName argument is a string that contains the name of the key Returns A str...

Page 42: ...eValue for var i 0 i theKeys length i theValue MMNotes get noteHandle theKeys i noteString theKeys i theValue n document theForm bigTextField value noteString always close noteHandle MMNotes close not...

Page 43: ...floating panel or data translator returns Dreamweaver Calling the MMNotes getVersionName function from Fireworks also returns Dreamweaver because Fireworks uses the same version of the library which w...

Page 44: ...ed The bForceCreate argument is a Boolean value that indicates whether to create the note even if Design Notes is turned off for the site or if the filePath argument is not associated with any site Re...

Page 45: ...e of an existing key and then closes the Design Notes file var noteHandle MMNotes open file c sites dreamcentral peakhike99 index html true if noteHandle 0 MMNotes set noteHandle Author M G Miller MMN...

Page 46: ...rive path to a file URL Arguments const char drivePath char localURLBuf int localURLMaxLen The drivePath argument is a string that contains the full drive path The localURLBuf argument is the buffer w...

Page 47: ...ted with the welcome html file FileHandle noteHandle OpenNotesFile file c sites avocado8 iwjs welcome html if noteHandle 0 int valueLength GetNoteLength noteHandle comments char valueBuffer new char v...

Page 48: ...returns The keyBufArray 64 argument is the buffer array where the keys are stored The keyArrayMaxLen argument is the integer that GetNotesKeyCount noteHandle returns indicating the maximum number of...

Page 49: ...e siteRootBufMaxLen argument is the maximum size of the buffer that siteRootBuf references The infoPrefs argument which is optional is a reference to a struct in which the preferences for the site are...

Page 50: ...versionNumBuf int versionNumBufMaxLen The versionNumBuf argument is the buffer where the version number is stored The versionNumBufMaxLen argument is the maximum size of the buffer that versionNumBuf...

Page 51: ...eHandle OpenNotesFilewithOpenFlags Description This function opens the Design Notes file that is associated with the specified file or creates one if none exists You can open the file in read only mod...

Page 52: ...remove Returns A Boolean value true indicates the operation is successful false otherwise BOOL SetNote Description This function creates or updates one key value pair in a Design Notes file Arguments...

Page 53: ...al For general information on how C libraries interact with the JavaScript interpreter in Macromedia Dreamweaver 8 see Extending Dreamweaver for details on C level extensibility The FWLaunch API The F...

Page 54: ...L argument which is expressed as a file URL is either a string of literal JavaScript or the path to a JavaScript file Returns A cookie object if the JavaScript passes successfully or a nonzero error c...

Page 55: ...reworks function returns Returns A string that contains the result of the script passed to the FWLaunch execJsInFireworks function if the operation completes successfully a null value if Fireworks is...

Page 56: ...sCookie if response null if typeof response number error or user cancel time to close the window and let the user know we got an error window close alert An error occurred else got a valid response al...

Page 57: ...getHeight argument which is optional defines the height to which the image should be resized Returns Zero if a Fireworks optimization session successfully opens for the specified image otherwise a non...

Page 58: ...e specified version of Fireworks was found Example The following code checks whether Fireworks is installed if FWLaunch validateFireworks 6 0 alert Fireworks 6 0 or later is installed else alert Firew...

Page 59: ...of gProgressTrackerCookie number window close alert an error occurred gProgressTrackerCookie null else bring Fireworks to the front FWLaunch bringFWToFront start the checking to see if Fireworks is do...

Page 60: ...s be a useful one since not all functions in Fireworks return a string but we know this one does so we can show the user what we got window close FWLaunch bringDWToFront bring Dreamweaver to the front...

Page 61: ...nds see Extending Dreamweaver How Flash elements work Flash elements are packaged as SWC files A SWC file is a compiled component movie clip that is generated by Flash for use by Macromedia and third...

Page 62: ...a file that details the parameters the user can edit Dreamweaver then inserts the SWF file into the user s document Adding a Flash element to the Insert Bar As with other objects you add a Flash eleme...

Page 63: ...r image file The API lets you create new Flash objects as well as read and manipulate existing Flash objects The Flash button and Flash text features are built using this API The SWT file is a Flash G...

Page 64: ...ressed as a file URL is the output filename of a PNG file This argument is optional The jpgFileName argument which is expressed as a file URL is the output filename of a JPEG file This argument is opt...

Page 65: ...Template file with the string Hello World It creates a GIF file as well as a SWF file var params new Array params 0 dwType params 1 myType params 2 text params 3 Hello World errorString SWFFile creat...

Page 66: ...f file is a Flash object of type myType if SWFFile getObjectType file MyMac test swf myType alert This is a myType object else alert This is not a myType object SWFFile readFile Description This funct...

Page 67: ...le readFile file MyMac test swf returns the following values in the parameters array file MyMac test swt template file used to create this swf file dwType first parameter myType first parameter value...

Page 68: ...68 Flash Integration...

Page 69: ...e query or stored procedure When accessing a database through this API you use structured query language SQL statements Database API functions are used at design time when users are building web appli...

Page 70: ...ypeArray Database connection functions Database connection functions let you make and manage any connection including the Dreamweaver provided ADO ColdFusion and JDBC connections These functions inter...

Page 71: ...on selectedObj name dw serverComponents refresh MMDB getColdFusionDsnList Availability Dreamweaver UltraDev 4 Description This function gets the ColdFusion data source names DSNs from the site server...

Page 72: ...to use a remote driver HTTP connection at design time otherwise use a local driver DLL includePattern Regular expression used to find the file include statement on the page during Live Data and Previe...

Page 73: ...unction gets the connection name that corresponds to the specified connection string This function is useful when you need to reselect a connection name in the user interface UI from data on the page...

Page 74: ...ng argument Returns A connection name string that corresponds to the connection string Example The following code returns the string EmpDB var connectionName MMDB getConnectionName dsn EmpDB uid pwd M...

Page 75: ...driver name Arguments connName The connName argument is a connection name that is specified in the Connection Manager It identifies the connection string that Dreamweaver should use to make a database...

Page 76: ...ntry to the XML and Dreamweaver MX or later developers need to implement a new dialog box Description This function gets JDBC Drivers and respective URL templates Arguments None Returns An array that...

Page 77: ...ve data source Returns A password string that is associated with the connection name Example The statement MMDB getPassword EmpDB might return joessecret MMDB getRDSPassword Availability Dreamweaver U...

Page 78: ...a parameter string this function passes it to the HTTP connectivity scripts Arguments urlParams The urlParams argument which is optional is a string that contains a list of name value expressions whi...

Page 79: ...e following code returns the string ADO for an ADO connection var connectionType MMDB getRuntimeConnectionType EmpDB MMDB getUserName Availability Dreamweaver UltraDev 1 Description This function retu...

Page 80: ...name exists false otherwise MMDB needToPromptForRdsInfo Availability Dreamweaver MX Description This function determines whether Dreamweaver should open the RDS Login Information dialog box Arguments...

Page 81: ...dialogFileName a string the popupConnection function makes Dreamweaver open the Connection dialog box so you can define a new connection If the argument list consists only of connRec a connection ref...

Page 82: ...nctions and then include that file in the HTML file For more information on creating a connection see The Database Connectivity API on page 101 The connRec argument is a reference to an existing Conne...

Page 83: ...ays the ColdFusion Administrator dialog box Arguments None Returns Nothing The ColdFusion Administrator dialog box appears MMDB showConnectionMgrDialog Availability Dreamweaver UltraDev 1 Description...

Page 84: ...Dreamweaver UltraDev 4 Description This function displays the RDS user name and password dialog box Arguments username password The username argument is the initial user name The password argument is...

Page 85: ...t contains values from the following list which are appropriate for the current server model For properties that do not apply to the connection being tested set them to empty The type argument indicat...

Page 86: ...he stored procedure requires the parameters Second you specify parameter values to provide an array of parameter names paramNameArray You can use the MMDB getSPParamsAsString function to get the param...

Page 87: ...a connection name that is specified in the Connection Manager It identifies the connection string that Dreamweaver should use to make a database connection to a live data source The statement argumen...

Page 88: ...ch it is associated Example The following example uses MMDB getColumns to set the tooltip text value var columnNameObjs MMDB getColumns connName tableName var databaseType MMDB getDatabaseType connNam...

Page 89: ...argument Returns An array of strings where each string is the name of a column in the table Example The statement MMDB getColumnsOfTable EmpDB Employees returns the following strings EmpID FirstName L...

Page 90: ...pecified table var connName componentRec parent parent parent name var tableName componentRec name var primaryKeys MMDB getPrimaryKeys connName tableName MMDB getProcedures Availability Dreamweaver MX...

Page 91: ...me You must first create a schema or catalog in your database application before you can apply it in Dreamweaver Consult your database documentation or your system administrator Name of the schema tha...

Page 92: ...uesArray argument is an array that contains a list of design time parameter test values Specify the parameter values in the order in which the stored procedure expects them You can use the MMDB getSPP...

Page 93: ...re The paramValuesArray argument is an array that contains a list of design time parameter test values You can specify if the procedure requires parameters when it executes If you have provided parame...

Page 94: ...ects each specifying the following set of properties Example The following example retrieves the parameter objects for the specified procedure and creates a tooltip for each object using its propertie...

Page 95: ...a live data source The procName argument is the name of the stored procedure Returns A comma delimited string that contains the list of parameters that the stored procedure requires The parameters nam...

Page 96: ...he catalog that contains the table Example The statement MMDB getTables EmpDB might produce an array of two objects The first object s properties might be similar to the following example object1 tabl...

Page 97: ...w catalog if thisSchema length 0 thisSchema views push String thisSchema thisView view MMDB showResultset Availability Dreamweaver UltraDev 1 Description This function displays a dialog box that conta...

Page 98: ...he stored procedure Arguments connName procName paramValuesArray The connName argument is a connection name that is specified in the Connection Manager It identifies the connection string that Dreamwe...

Page 99: ...me argument is a connection name that is specified in the Connection Manager It identifies the connection string that Dreamweaver should use to make a database connection to a live data source The pro...

Page 100: ...100 The Database API...

Page 101: ...Source Name How to develop a new connection type The following steps outline the process for creating a new connection type 1 Create the layout for the connection dialog box Create an HTML file that l...

Page 102: ...this implementation file but it must have a js extension for example myConnectionImpl js You can store this implementation file on either your local or a remote computer You might want to store your...

Page 103: ...include file You can see examples of the HTML source in The generated include file on page 107 The findConnection function takes the HTML source and extracts its properties You can implement findConne...

Page 104: ...Dev 4 Description Dreamweaver calls this function to detect a connection in the specified HTML source and to parse the connection parameters If the contents of this source file match the criteria for...

Page 105: ...at design time otherwise Dreamweaver uses design time properties useHTTP String containing either true or false true specifies to use HTTP connection at design time false specifies to use DLL includeP...

Page 106: ...is function when the user clicks OK in the connection dialog box The applyConnection function generates the HTML source for a connection Dreamweaver writes the HTML to the Configuration Connections co...

Page 107: ...1_STRING dsn pubs The server behavior file includes this connection by using the relative file include statement as shown in the following example include file Connections MyConnection1 asp ColdFusion...

Page 108: ...statement as shown in the following example cfinclude template Connections MyConnection1 cfm JSP The JSP include file should be named MyConnection1 jsp where MyConnection1 is the name of your connect...

Page 109: ...ction_includefile version 5 0 quickSearch CDATA HTTP quickSearch insertText location CDATA FileName filename Type type designtimeString DesigntimeType designtimeType HTTP http Catalog catalog Server m...

Page 110: ...name in this example map values in the include file to properties of a connection object You set the properties of connection objects in the JavaScript implementation file All the default connection d...

Page 111: ...JavaBeans the JavaBeans must reside in the Configuration Classes folder The JavaBeans API The following functions are methods of the MMJB object MMJB getClasses Availability Dreamweaver UltraDev 4 Des...

Page 112: ...Enterprise zip Returns A string array of class names inside the particular JAR or ZIP Java archive an error returns an empty array MMJB getErrorMessage Availability Dreamweaver UltraDev 4 Description...

Page 113: ...aDev 4 enhanced in Dreamweaver MX Description Introspects the JavaBeans class and returns its indexed properties which are design patterns that behave the same way as collections Arguments packageName...

Page 114: ...className an error returns an empty array MMJB getProperties Availability Dreamweaver UltraDev 4 enhanced in Dreamweaver MX Description Introspects the JavaBeans class and returns its properties Argum...

Page 115: ...ay of read only properties associated with className an error returns an empty array MMJB getWriteProperties Availability Dreamweaver MX Description Gets write only properties for JavaBeans that suppo...

Page 116: ...116 The JavaBeans API...

Page 117: ...s for each API function If an address does not exist Dreamweaver assumes the library does not support the API If the address exists Dreamweaver uses the library s version of the function to support th...

Page 118: ...eature Dreamweaver transports Design Note MNO files to maintain the Design Notes as it does with FTP and LAN Check In Check Out is treated differently than the Design Notes feature if the source contr...

Page 119: ...ystem The name appears in the combo box for selecting a source control system on the Source Control tab in the Edit Sites dialog box The name can be a maximum of 32 characters The version argument is...

Page 120: ...eaver to pass to it when calling other API functions The siteName argument is a string that points to the name of the site The site name can be a maximum of 64 characters Returns A Boolean value true...

Page 121: ...eger that indicates the length of the name of the root folder If the function returns 0 Dreamweaver considers it an error and tries to retrieve the error message from the DLL if supported bool SCS_Get...

Page 122: ...upported bool SCS_GetFolderList Description This function returns a list of files and folders in the passed in folder including pertinent information such as modified date size and whether the item is...

Page 123: ...sed into Dreamweaver during the Connect call The remotePathList argument is a list of the remote files or folders to retrieve which is specified as complete paths and names The localPathList argument...

Page 124: ...remotePathList argument is a mirrored list of remote filenames or folder paths The numItems argument is the number of items in each list Returns A Boolean value true if successful false otherwise bool...

Page 125: ...emotePath equals folder1 file1 and newRemotePath equals folder1 renamefile1 file1 is renamed renamefile1 and is located in folder1 If oldRemotePath equals folder1 file1 and newRemotePath equals folder...

Page 126: ...equired and optional functions The functions in this section are optional bool SCS_GetConnectionInfo Description This function displays a dialog box to let the user change or set the connection inform...

Page 127: ...SiteRenamed Description This function notifies the DLL when the user has renamed the site so that it can update its persistent information about the site Arguments const char oldSiteName 64 const char...

Page 128: ...to add to the main and context menus Each string can contain a maximum of 32 characters The functionList argument is populated by the DLL it specifies the routines in the DLL to call when the user se...

Page 129: ...s function checks a list of local files or folders into the source control system The DLL is responsible for making the file read only If it is unsupported by the source control system and this featur...

Page 130: ...data that passed into Dreamweaver during the Connect call The remotePathList argument is a list of remote filenames or folder paths to check out The localPathList argument is a mirrored list of local...

Page 131: ...know which corresponding files check outs are undone successfully The numItems argument is the number of items in each list Returns A Boolean value true if successful false otherwise int SCS_GetNumCh...

Page 132: ...of 64 characters The emailAddressList argument is a list of strings that corresponds to the users e mail addresses Each e mail address string cannot exceed a maximum length of 64 characters The numChe...

Page 133: ...he buffer represented by the errorMsg argument Returns A Boolean value true if successful false otherwise int SCS_GetNoteCount Description This function returns the number of Design Note keys for the...

Page 134: ...amweaver considers it an error and tries to retrieve the error message from the DLL if supported bool SCS_GetDesignNotes Description This function retrieves key value pairs from the meta information f...

Page 135: ...oid connectionData const char remotePath const char keyList 64 const char valueList bool showColumnList const int noteCount const int noteLength The connectionData argument is a pointer to the agent s...

Page 136: ...the agent s data that passed into Dreamweaver during the Connect call The remotePathList argument is a list of remote filenames or folder paths to compare for newer status The localPathList argument i...

Page 137: ...ssful false otherwise bool SCS_canGet Description This function returns whether the Get menu item should be enabled Arguments void connectionData const char remotePathList const char localPathList con...

Page 138: ...the number of items in each list Returns A Boolean value true if successful false otherwise bool SCS_canPut Description This function returns whether the Put menu item should be enabled Arguments voi...

Page 139: ...ber of items in each list Returns A Boolean value true if successful false otherwise bool SCS_CanUndoCheckout Description This function returns whether the Undo Checkout menu item should be enabled Ar...

Page 140: ...ed Returns A Boolean value true if successful false otherwise bool SCS_canDelete Description This function returns whether the Delete menu item should be enabled Arguments void connectionData const ch...

Page 141: ...unction lets your DLL perform one operation such as adding a check out comment to a group of files Arguments connectionData The connectionData argument is a pointer to the agent s data that passed int...

Page 142: ...he DLL in the following order SCS_BeforePut connectionData SCS_Put connectionData localPathList1 remotePathList1 successList1 SCS_Put connectionData localPathList2 remotePathList2 successList2 SCS_Put...

Page 143: ...les This function lets the DLL perform any operation after a batch put or check in such as creating a summary dialog box Arguments connectionData The connectionData argument is a pointer to the agent...

Page 144: ...144 The Source Control Integration API...

Page 145: ...a document You can use these functions to perform any task that the user can accomplish using menus floating panels property inspectors the Site panel or the Document window Chapter 10 Application 147...

Page 146: ......

Page 147: ...and to the browsers and external editors that are defined in the Preview in Browser and External Editors preferences These functions let you get information about these external applications and open...

Page 148: ...browseDocument http www hotwired com In Dreamweaver 4 you can expand this operation to open the document in Microsoft Internet Explorer using the following code function goToHotwired var prevBrowsers...

Page 149: ...a complete file URL a filename or a file extension including the period Returns An array that contains a pair of strings for each editor in the list The first string in each pair is the name of the e...

Page 150: ...editor Element 1 is a string that contains the path to the Flash application on the local computer which is expressed as a file URL If Flash is not installed it returns nothing Example The following e...

Page 151: ...rimary editor for the specified file Arguments fileURL The fileURL argument is the path to the file to open which is expressed as a file URL Returns An array that contains a pair of strings The first...

Page 152: ...f the HTML Help files images and indexes In Windows the Help book is a file that has a name with a chm extension On the Macintosh the Help book is a folder The Help book files reside in the Dreamweave...

Page 153: ...s the following format ID page The ID portion is the bookID of the entry in the help xml file that names the file that contains the help content to display The page portion of the entry identifies the...

Page 154: ...e Arguments fileURL The fileURL argument is the path to the file to open which is expressed as a file URL Returns Nothing dreamweaver openWithExternalTextEditor Availability Dreamweaver 3 Description...

Page 155: ...ther Flash MX or a later version is installed on the local computer Arguments None Returns A Boolean value true if Flash MX or a later version is installed on the local computer false otherwise Global...

Page 156: ...a message that the alert function displays beep if confirm Is your order complete dreamweaver beep alert Click OK to submit your order dreamweaver getShowDialogsOnInsert Availability Dreamweaver 3 De...

Page 157: ...uits Dreamweaver after the script that calls this function finishes executing Arguments None Returns Nothing dreamweaver showAboutBox Availability Dreamweaver 3 Description Opens the About dialog box...

Page 158: ...dialog box controls so they appear exactly as when the user clicked OK to create this string Dreamweaver passes this string to the inspectDynamicDataRef function to determine if the string matches any...

Page 159: ...l format for the Code Format category code hints html rewriting for the Code Rewriting category copyPaste css styles file compare external editors for the File Types Editors category fonts highlightin...

Page 160: ...g box for users to insert tags into the Code view The function shows the Tag Chooser dialog box on top of all other Dreamweaver windows If the dialog box is not visible the function opens it brings it...

Page 161: ...oning a toolbar and getting or setting focus History functions History functions handle undoing redoing recording and playing steps that appear in the History panel A step is any repeatable change to...

Page 162: ...iption Gets the text that is associated with the editing operation that will be redone if the user selects Edit Redo or presses Control Y Windows or Command Y Macintosh Arguments None Returns A string...

Page 163: ...g that contains the text that is associated with the editing operation that will be undone Example If the user s last action applied a cascading style sheet CSS style to a selected range of text a cal...

Page 164: ...el or Site panel Arguments None Returns Nothing Enabler See dreamweaver canRedo on page 570 dreamweaver startRecording Availability Dreamweaver 3 Description Starts recording steps in the active docum...

Page 165: ...bler See dreamweaver isRecording on page 579 must return a value of true dreamweaver undo Availability Dreamweaver 3 Description Undoes the previous step in the Document window dialog box floating pan...

Page 166: ...if the specified steps include an unrepeatable action Arguments arrayOfIndices The arrayOfIndices argument is an array of position indices in the History panel Returns A string that contains the JavaS...

Page 167: ...he dreamweaver historyPalette getSelectedSteps function returns 1 2 3 dreamweaver historyPalette getStepCount Availability Dreamweaver 3 Description Gets the number of steps in the History panel Argum...

Page 168: ...nel a call to the dreamweaver historyPalette getStepsAsJavaScript dw historyPalette getSelect edSteps function returns dw getDocumentDOM insertText Hey diddle diddle a cat and a fiddle the cow jumped...

Page 169: ...to the specified history steps Example A call to dreamweaver historyPalette replaySteps 0 2 3 function plays the first third and fourth steps in the History panel dreamweaver historyPalette saveAsComm...

Page 170: ...array of position indices in the History panel If no argument is supplied all the steps are unselected Returns Nothing Example The following example selects the first second and third steps in the His...

Page 171: ...le resides in the Configuration Objects FlashElements folder or subfolder Arguments swcFilename The swcFilename string is the path and name of the desired flash component relative to the Configuration...

Page 172: ...nsert bar The user can click on the default object to insert it or click on the arrow beside the default object to open the pop up menu and see the other objects in that menu Dreamweaver sets the new...

Page 173: ...pace Delete Page Up and Page Down keys In addition to such general arrow and key functions as arrowLeft and backspaceKey Dreamweaver also provides methods for moving to the next or previous word or pa...

Page 174: ...e that indicates whether to extend the selection If this argument is omitted the default is false Returns Nothing dom arrowRight Availability Dreamweaver 3 Description Moves the insertion point to the...

Page 175: ...s optional is a Boolean value that indicates whether to extend the selection If this argument is omitted the default is false Returns Nothing dom backspaceKey Availability Dreamweaver 3 Description Th...

Page 176: ...operation must occur If the argument is omitted the default is 1 Returns Nothing dom endOfDocument Availability Dreamweaver 3 Description Moves the insertion point to the end of the document that is a...

Page 177: ...g dom nextParagraph Availability Dreamweaver 3 Description Moves the insertion point to the beginning of the next paragraph or skips multiple paragraphs if nTimes is greater than 1 Arguments nTimes bS...

Page 178: ...lean value that indicates whether to extend the selection If this argument is omitted the default is false Returns Nothing dom pageDown Availability Dreamweaver 3 Description Moves the insertion point...

Page 179: ...he selection If this argument is omitted the default is false Returns Nothing dom previousParagraph Availability Dreamweaver 3 Description Moves the insertion point to the beginning of the previous pa...

Page 180: ...nal is a Boolean value that indicates whether to extend the selection If this argument is omitted the default is false Returns Nothing dom startOfDocument Availability Dreamweaver 3 Description Moves...

Page 181: ...alse Returns Nothing dreamweaver mapKeyCodeToChar Availability Dreamweaver 4 Description Takes a key code as retrieved from the event object s keyCode field and translates it to a character You should...

Page 182: ...y Dreamweaver 3 Description Checks whether the specified menu needs to be updated Arguments menuId The menuId argument is a string that contains the value of the id attribute for the menu item as spec...

Page 183: ...dw getFontList dw getDocumentList dw htmlStylePalette getStyles or site getSites Returns Nothing dreamweaver reloadMenus Availability Dreamweaver 3 Description Reloads the entire menu structure from...

Page 184: ...004 Description Opens the specified results floating panel and selects the item Arguments floaterName floaterIndex The floaterName argument is a string that specifies the results floating panel to ope...

Page 185: ...ity Dreamweaver 4 Description Adds a new item to the Results window Arguments resultWindowObj strIcon strDesc itemData iStartSel iEndSel colNdata The resultWindowObj argument is the object that the cr...

Page 186: ...headings Frodo Sam and Gollum The call to the resWin addItem function adds a folder icon and then the three strings msg1 msg2 and msg3 into the three columns defined for the window var resWin dw crea...

Page 187: ...olumn of the Results window usually the filename The strDesc argument is the description that goes with the entry The iLineNo argument is the number of lines in the file optional The iStartSel argumen...

Page 188: ...e addItem function resWin getItemCount Availability Dreamweaver 4 Description Retrieves the number of items in the list Arguments None Returns The number of items in the list resWin getSelectedItem Av...

Page 189: ...s clicked This is similar to the way the commandButtons function works for commands Only two buttons can be set in the window Returns Nothing resWin setCallbackCommands Availability Dreamweaver 4 Desc...

Page 190: ...nds to process Arguments arrFilePaths bRecursive The arrFilePaths argument is an array of file or folder paths to iterate through The bRecursive argument is a Boolean value that indicates whether the...

Page 191: ...guments strTitle The strTitle argument is the new name of the floating panel Returns Nothing resWin startProcessing Availability Dreamweaver 4 Description Starts processing the file Arguments None Ret...

Page 192: ...se the following methods that are defined for stand alone Results windows dreamweaver resultsPalette siteReports dreamweaver resultsPalette validator dreamweaver resultsPalette btc Target Browser Chec...

Page 193: ...indow that is in focus often used for the FTP logging window Arguments None Returns Nothing Enabler See dreamweaver resultsPalette canCopy on page 580 dreamweaver resultsPalette cut Availability Dream...

Page 194: ...Arguments None Returns Nothing Enabler See dreamweaver resultsPalette canPaste on page 580 dreamweaver resultsPalette openInBrowser Availability Dreamweaver MX Description Sends a report Site Reports...

Page 195: ...pens the document in the editor Arguments None Returns Nothing Enabler See dreamweaver resultsPalette canOpenInEditor on page 581 dreamweaver resultsPalette save Availability Dreamweaver MX Descriptio...

Page 196: ...hes the response for a packet of XML that has a known signature If Dreamweaver finds XML with that signature it processes the XML and displays the contained information in a tree control This tree dis...

Page 197: ...XML string that the server returns The XML string should use the following formatting server debug node Root node for the debug XML data debugnode Corresponds to every node context Name of item that a...

Page 198: ...databaseName Pubs value debugnode debugnode debugnode name CDATA Element Snippet is undefined in class coldfusion compiler TagInfoNotFoundException name icon CDATA ServerDebugOutput ColdFusion Excepti...

Page 199: ...function determines whether visual aids are set as hidden Arguments None Returns A Boolean value true sets Hide All Visual Aids to hidden false otherwise dom getPreventLayerOverlaps Availability Drea...

Page 200: ...rue if auto indenting is on false otherwise dom getShowFrameBorders Availability Dreamweaver 3 Description This function gets the current state of the View Frame Borders option Arguments None Returns...

Page 201: ...e true indicates the head content is visible false otherwise dom getShowInvalidHTML Availability Dreamweaver 4 Description This function determines whether invalid HTML code is currently highlighted i...

Page 202: ...iew Invisible Elements option Arguments None Returns A Boolean value true indicates the invisible element markers are visible false otherwise dom getShowLayerBorders Availability Dreamweaver 3 Descrip...

Page 203: ...Dreamweaver 3 Description This function gets the current state of the View Rulers Show option Arguments None Returns A Boolean value true indicates the rulers are visible false otherwise dom getShowS...

Page 204: ...tes the table borders are visible false otherwise dom getShowToolbar Availability Dreamweaver 4 Description This function determines whether the toolbar appears Arguments None Returns A Boolean value...

Page 205: ...s None Returns A Boolean value true if word wrap is on false otherwise dom getSnapToGrid Availability Dreamweaver 3 Description This function gets the current state of the View Grid Snap To option Arg...

Page 206: ...display of all borders image maps and invisible elements regardless of their individual settings in the View menu Arguments bSet The bSet argument is a Boolean value true hides visual aids false othe...

Page 207: ...FrameBorders The bShowFrameBorders argument is a Boolean value true turns the Frame Borders on false otherwise Returns Nothing dom setShowGrid Availability Dreamweaver 3 Description This function togg...

Page 208: ...tion false turns it off Returns Nothing dom setShowInvalidHTML Availability Dreamweaver 4 Description This function turns highlighting of invalid HTML code on or off in the Code view of the document w...

Page 209: ...urns it off Returns Nothing dom setShowInvisibleElements Availability Dreamweaver 3 Description This function toggles the View Invisible Elements option on and off Arguments bViewInvisibleElements The...

Page 210: ...hides the line numbers in the Code view of the document window Arguments bShow The bShow argument is a Boolean value true indicates the line numbers should be visible false hides them Returns Nothing...

Page 211: ...t syntax coloring should be visible false otherwise Returns Nothing dom setShowTableBorders Availability Dreamweaver 3 Description This function toggles the View Table Borders option on and off Argume...

Page 212: ...acing Image Show option on and off Arguments bShowTracingImage The bShowTracingImage argument is a Boolean value true turns on the Show option false turns it off Returns Nothing dom setShowWordWrap Av...

Page 213: ...e bSnapToGrid argument is a Boolean value true turns on the Snap To option false turns it off Returns Nothing dreamweaver getHideAllFloaters Availability Dreamweaver 3 Description This function gets t...

Page 214: ...reamweaver htmlInspector getShowAutoIndent Availability Dreamweaver 4 Description This function determines whether the Auto Indent option is on in the Code inspector Arguments None Returns A Boolean v...

Page 215: ...e Returns A Boolean value true if line numbers appear false otherwise dreamweaver htmlInspector getShowSyntaxColoring Availability Dreamweaver 4 Description This function determines whether syntax col...

Page 216: ...s bShow The bShow argument is a Boolean value true turns the auto indenting on false turns it off Returns Nothing dreamweaver htmlInspector setShowInvalidHTML Availability Dreamweaver 4 Description Th...

Page 217: ...rgument is a Boolean value true sets the line numbers to visible false hides them Returns Nothing dreamweaver htmlInspector setShowSyntaxColoring Availability Dreamweaver 4 Description This function t...

Page 218: ...Returns Nothing dreamweaver setHideAllFloaters Availability Dreamweaver 3 Description This function sets either the Hide Panels option or the Show Panels option Arguments bShowFloatingPalettes The bSh...

Page 219: ...ent state of the Show Dependent Files option Arguments None Returns A Boolean value true indicates that dependent files are visible in the site map false indicates dependent files are not visible site...

Page 220: ...visible in the site map false otherwise site getShowToolTips Availability Dreamweaver 3 Description This function gets the current state of the Tool Tips option Arguments None Returns A Boolean value...

Page 221: ...Hidden option in the site map on or off Arguments bShowHiddenFiles The bShowHiddenFiles argument is a Boolean value true turns on the Show Files Marked as Hidden option false turns it off Returns Not...

Page 222: ...wing JavaScript functions let you get and set the visibility of toolbars and toolbar labels obtain the labels of toolbar items in the current window position toolbars and obtain toolbar IDs For more i...

Page 223: ...ue if labels for buttons are visible in the current document window false otherwise Example The following example makes labels for buttons visible var dom dw getDocumentDom if dom getShowToolbarIconLa...

Page 224: ...e itemID argument is a string that specifies the ID of the item for which you want the value Returns A string that represents the value of the toolbar item Example The following example of receiveArgu...

Page 225: ...bel name string that is assigned as an attribute on the toolbar tag Example The following example stores the label for myEditbar in the variable label var label dom getToolbarLabel myEditbar dom getTo...

Page 226: ...string that specifies the ID of the toolbar item The attrName argument is a string that specifies the name of the attribute to set Valid values are image overImage disabledImage or tooltip The attrVal...

Page 227: ...false otherwise Returns Nothing Example The following example tells Dreamweaver to show the labels for the buttons on the toolbars dom setShowToolbarIconLabels true dom setToolbarPosition Availabilit...

Page 228: ...the same way as top relative_to toolbar_id is required if position specifies below Otherwise it is ignored Specifies the ID of the toolbar below which this toolbar should be positioned Returns Nothin...

Page 229: ...set the active document For operations that are related specifically to the Site panel see Site functions on page 256 dom getFocus Availability Dreamweaver 3 Description This function determines the p...

Page 230: ...lity Dreamweaver 3 Description This function gets the title of the window that contains the document Arguments None Returns A string that contains the text that appears between the TITLE tags in the d...

Page 231: ...y making it flash which is slightly different functionality than dw toggleFloater Arguments floaterName The floaterName argument is the name of the window panel or inspector Returns Nothing Example Th...

Page 232: ...ct that corresponds to the document in the active window or if the document is in a frame the document object that corresponds to the frameset dreamweaver getDocumentList Availability Dreamweaver 3 De...

Page 233: ...terName htm where floaterName is the name of a floating panel The floaterName values for built in Dreamweaver panels are the strings to the right of the panel names in the following list Assets assets...

Page 234: ...alse otherwise Returns One of the following strings The document string if the document window is in focus The site string if the Site panel is in focus The textView string if the Text view is in focu...

Page 235: ...or on the top in a split view dreamweaver getSnapDistance Availability Dreamweaver 4 Description This function returns the snapping distance in pixels Arguments None Returns An integer that represent...

Page 236: ...ject argument is the object at the root of a document s DOM tree the value that the dreamweaver getDocumentDOM function returns The bActivateFrame argument is optional and is applicable only if docume...

Page 237: ...has no effect The floaterName values for built in Dreamweaver panels are the strings to the right of the panel names in the following list Assets assets Behaviors behaviors Bindings data sources Code...

Page 238: ...ew at the top of the document window Arguments viewString The viewString argument is the view to display at the top of the document window it can be one of the following values design or code Returns...

Page 239: ...amweaver 3 Description This function makes the Property inspector visible and gives it focus Arguments None Returns Nothing dreamweaver tileHorizontally Availability Dreamweaver MX Windows only Dreamw...

Page 240: ...the other without overlapping documents This is similar to splitting the workspace horizontally Arguments None Returns Nothing Example The following example tiles the open documents vertically dw til...

Page 241: ...erence Availability Dreamweaver 4 Description This function updates the Reference floating panel If the Reference floating panel is not visible dw updateReference makes it visible and then updates it...

Page 242: ...rrent selection in Code view that starts just before the start tag and ends just after the end tag var currentDOM dw getDocumentDOM currentDOM collapseFullTag false dom collapseFullTagInverse Availabi...

Page 243: ...collapsed this function does nothing Arguments allowCodeFragmentAdjustment The allowCodeFragmentAdjustment is a required Boolean value If true Dreamweaver modifies the boundaries of the current select...

Page 244: ...apses the code fragments exactly as indicated by the selection Returns Nothing Example The following example adjusts and then collapses all code before and after the selected code in Code view var cur...

Page 245: ...lability Dreamweaver 8 Description This function determines whether the selection in the Code inspector is entirely within a single pair of start and end tags or contains a single pair of start and en...

Page 246: ...d tag if not the function does nothing Arguments allowAdjustmentOfCodeFragments The allowAdjustmentOfCodeFragments argument is a required Boolean value If true Dreamweaver adjusts the boundaries of th...

Page 247: ...ollapses the selected code in the Code inspector dreamweaver htmlInspector collapseSelectedCodeFragment true dreamweaver htmlInspector collapseSelectedCode FragmentInverse Availability Dreamweaver 8 D...

Page 248: ...collapsed code fragments in the Code inspector including nested collapsed code fragments Arguments None Returns Nothing Example The following example expands all collapsed code in the Code inspector...

Page 249: ...dom getOpenPathName Availability Dreamweaver 8 Description This function gets the absolute file path of the open document Arguments None Returns A string that is the absolute file path of the open doc...

Page 250: ...the display of special characters is turned on initially var currentDOM dw getDocumentDOM if currentDOM getShowHiddenCharacters currentDOM setShowHiddenCharacters false dom setShowHiddenCharacters Av...

Page 251: ...s null the function inserts the text specified in the beforeText argument at the beginning of every line in the current selection Arguments beforeText The beforeText argument is required It specifies...

Page 252: ...ext The beforeText argument is optional It specifies the text to identify the beginning of the comment to remove from the selection or if the value of the afterText argument is null it specifies the t...

Page 253: ...aracters false dreamweaver htmlInspector setShowHiddenCharacters Availability Dreamweaver 8 Description This function shows or hides the special characters for white spaces in the Code view of the Cod...

Page 254: ...254 Workspace...

Page 255: ...port functions Report functions provide access to the Macromedia Dreamweaver 8 reporting features so you can initiate monitor and customize the reporting process For more information see Reports in Ex...

Page 256: ...perform the following tasks Create links between files Get put check in and check out files Select and deselect files Create and remove files Get information about the sites that the user has defined...

Page 257: ...ilePath The localFilePath attribute which is required is a string that contains the path to a local file on your local computer Returns A string which specifies the site relative URI Example The follo...

Page 258: ...Info section of the Site Definition dialog box dreamweaver compareFiles Availability Dreamweaver 8 Description This function launches the file comparison tool that the user installed in the Diff sect...

Page 259: ...connected Arguments None Returns Nothing dreamweaver saveSitesToPrefs Availability Dreamweaver 4 Description Saves all information for each site that the user has defined to the system registry Window...

Page 260: ...unction changes the action for the selected items in the Site Synchronization dialog box to Delete Arguments None Returns Nothing Enabler See dreamweaver siteSyncDialog canMarkDelete on page 583 dream...

Page 261: ...nges the action for the selected items in the Site Synchronization dialog box to Ignore Arguments None Returns Nothing Enabler See dreamweaver siteSyncDialog canMarkIgnore on page 584 dreamweaver site...

Page 262: ...er See dreamweaver siteSyncDialog canMarkSynced on page 585 dreamweaver siteSyncDialog toggleShowAllFiles Availability Dreamweaver 8 Description This function lets you see which files Dreamweaver thin...

Page 263: ...selected document to that file Arguments None Returns Nothing Enabler See site canAddLink on page 586 site addLinkToNewFile Availability Dreamweaver 3 Description Opens the Link to New File dialog bo...

Page 264: ...ide dialog box Arguments None Returns Nothing site changeLink Availability Dreamweaver 3 Description Opens the Select HTML File dialog box to let the user select a new file for the link Arguments None...

Page 265: ...ow Me Again option in the Dependent Files dialog box and clicked No dependent files are not uploaded and no dialog box appears Arguments siteOrURL The siteOrURL argument must be the keyword site which...

Page 266: ...e downloaded and no dialog box appears If the user previously selected the Don t Show Me Again option in the Dependent Files dialog box and clicked No dependent files are not downloaded and no dialog...

Page 267: ...cloak should act on the specified folder and all its contents Returns Nothing Enabler See site canCloak on page 588 site compareFiles Availability Dreamweaver 8 Description This function launches the...

Page 268: ...the Site panel with their remote versions site compareFiles site site defineSites Availability Dreamweaver 3 Description This function opens the Edit Sites dialog box Arguments None Returns Nothing si...

Page 269: ...ents filesToDeploy The filesToDeploy argument is an array of filenames that Dreamweaver will deploy Returns A Boolean value true if the files deploy successfully false otherwise Example This example d...

Page 270: ...and Settings jlondon Desktop DWServer Images spacerfilepath refreshlocal TRUE cache FALSE httpaddress http curserver webserver remoteinfo accesstype ftp host dreamweaver remoteroot kojak user dream ch...

Page 271: ...erinfo servermodel ColdFusion urlprefix http dreamweaver kojak serverscripting CFML serverpageext connectionsmigrated TRUE useUD4andUD5pages TRUE defaultdoctype accesstype ftp host dreamweaver remoter...

Page 272: ...of the following ways If the user selects Prompt on Get Check Out in the Site FTP preferences the Dependent Files dialog box appears If the user previously selected the Don t Show Me Again option in t...

Page 273: ...er The current site is the site that is associated with the document that currently has focus If no document has focus the site that you opened in Dreamweaver is used Arguments None Returns One of the...

Page 274: ...lability Dreamweaver MX Description Gets the value of the URL prefix that is extracted from the HTTP address defined in the Local Info section of the site definition dialog It is the path that appears...

Page 275: ...or example denise site getCheckOutUserForFile Availability Dreamweaver 3 Description Gets the login and check out name of the user who has the specified file checked out Arguments fileName The fileNam...

Page 276: ...rue if cloaking is enabled for the current site false otherwise site getConnectionState Availability Dreamweaver 3 Description Gets the current connection state Arguments None Returns A Boolean value...

Page 277: ...howing in the Current Sites List in the Site panel site getFocus Availability Dreamweaver 3 Description Determines which pane of the Site panel has focus Arguments None Returns One of the following st...

Page 278: ...you opened in Dreamweaver is used Arguments None Returns The path to the files residing on the local computer for the current site site getSelection Availability Dreamweaver 3 Description Determines...

Page 279: ...g the string file for a named file Returns A string that contains the name of the site if any in which the specified file exists The string is empty when the specified file does not exist in any defin...

Page 280: ...attribute of the localinfo element does not exist on the local computer Dreamweaver prompts for a different local root folder Dreamweaver behaves the same way when it tries to locate the default imag...

Page 281: ...election in the Site panel or the specified folder is cloaked Arguments siteOrURL The siteOrURL argument must contain one of the following two values The keyword site which indicates that the isCloake...

Page 282: ...be either local or remote The siteOrURL argument must be the keyword site which indicates that the function should act on the selection in the Site panel or the URL for a single file Returns Nothing...

Page 283: ...s the first selected file or folder Arguments None Returns Nothing Enabler See site canMakeNewFileOrFolder on page 592 site makeNewFolder Availability Dreamweaver 3 Description Creates a new folder in...

Page 284: ...ite Availability Dreamweaver 3 Description Opens the Site Definition dialog box for a new unnamed site Arguments None Returns Nothing site open Availability Dreamweaver 3 Description Opens the files t...

Page 285: ...y selected the Don t Show Me Again option in the Dependent Files dialog box and clicked Yes dependent files are uploaded and no dialog box appears If the user previously selected the Don t Show Me Aga...

Page 286: ...e site canRecreateCache on page 593 site refresh Availability Dreamweaver 3 Description Refreshes the file listing on the specified side of the Site panel Arguments whichSide The whichSide argument mu...

Page 287: ...whether the drive is mounted site removeLink Availability Dreamweaver 3 Description Removes the selected link from the document above it in the site map Arguments None Returns Nothing Enabler See sit...

Page 288: ...alidator checks the entire current site Returns Nothing site saveAsImage Availability Dreamweaver 3 Description Opens the Save As dialog box to let the user save the site map as an image Arguments fil...

Page 289: ...urns Nothing site selectHomePage Availability Dreamweaver 3 Description Opens the Open File dialog box to let the user select a new home page Arguments None Returns Nothing site selectNewer Availabili...

Page 290: ...e this function lets you determine whether to disable functionality that requires server interaction Arguments None Returns A Boolean value that indicates whether Dreamweaver is currently interacting...

Page 291: ...y Dreamweaver MX Description Determines whether cloaking should be enabled for the current site Arguments enable The enable argument is a Boolean value that indicates whether cloaking should be enable...

Page 292: ...ite argument is the name of a defined site as it appears in the Current Sites list in the Site panel or the Edit Sites dialog box Returns Nothing Example If three sites are defined for example avocado...

Page 293: ...ns the Site Map Layout pane in the Site Definition dialog box Arguments None Returns Nothing Enabler See site canSetLayout on page 595 site setLinkVisibility Availability Dreamweaver 3 Description Sho...

Page 294: ...cription Converts a site relative URI reference to a local file path Arguments siteRelativeURI The siteRelativeURI attribute which is required is a string that contains the site relative URI Returns A...

Page 295: ...cloaks the current selection in the Site panel or the specified folder Arguments siteOrURL The siteOrURL argument must contain one of the following values The keyword site which indicates that the unC...

Page 296: ...undoCheckOut Availability Dreamweaver 3 Description Removes the lock files that are associated with the specified files from the local and remote sites and replaces the local copy of the specified fil...

Page 297: ...ions 297 site viewAsRoot Availability Dreamweaver 3 Description Temporarily moves the selected file to the top position in the site map Arguments None Returns Nothing Enabler See site canViewAsRoot on...

Page 298: ...298 Site...

Page 299: ...an absolute URL get the currently selected node perform URL encoding on a string or run a translator on the document Conversion functions Conversion functions convert tables to layers layers to table...

Page 300: ...om canConvertTablesToLayers on page 554 Command functions Command functions help you make the most of the files in the Configuration Commands folder They manage the Command menu and call commands from...

Page 301: ...t Table htm Returns Nothing dreamweaver runCommand Availability Dreamweaver 3 Description Executes the specified command it works the same as selecting the command from a menu If a dialog box is assoc...

Page 302: ...existing HTML documents into XHTML and exporting CSS to external files These functions accomplish such tasks as browsing for files or folders creating files based on templates closing documents and g...

Page 303: ...tems that are required for XHTML cleans up the tree and then writes the tree as clean XHTML The missing directives declarations elements and attributes that the convertToXHTML function adds to the DOM...

Page 304: ...rmal use an extension first calls the dreamweaver openDocument or dreamweaver getDocumentDOM functions to get a reference to the document The extension then calls the dom getIsXHTMLDocument function t...

Page 305: ...g box If this argument is a value of true the dialog box filters for image files if omitted it defaults to a value of false The bSupressSiteRootWarnings argument added in Dreamweaver 3 is a Boolean va...

Page 306: ...file URL Returns A string that contains the name of the folder which is expressed as a file URL Example The following code returns the URL of a folder return dreamweaver browseForFolderURL Select a Fo...

Page 307: ...ment to create as declared in the Dreamweaver Configuration DocumentTypes MMDocumentTypes xml file as the id attribute of the documenttype tag For example the type argument could be HTML ASP JS ASP VB...

Page 308: ...00 body html The default document type definition DTD declaration is XHTML 1 0 Transitional rather than Strict If the user adds a frameset to the document Dreamweaver switches the DTD to XHTML 1 0 Fra...

Page 309: ...pens a new XML file which is empty except for the XML directive Arguments None Returns The DOM of the new XML file Example The following example creates a new document which is empty except for the XM...

Page 310: ...to the specified file as XML This function operates on the document that has focus which must be a template If you do not specify a filename argument Dreamweaver MX opens a dialog box to request the...

Page 311: ...not supply a value These argument values have the following meanings The document value specifies the document that has focus and contains the current selection The parent value specifies the parent f...

Page 312: ...iption Provides access to the editable tree for a new empty document This function works in the same way as the getDocumetDOM function except that it points to a new document not an existing one and d...

Page 313: ...turns nothing dreamweaver importXMLIntoTemplate Availability Dreamweaver 3 Description Imports an XML text file into the current template document This function operates on the document that has focus...

Page 314: ...to cause the New Document dialog box to appear false otherwise Returns Nothing dreamweaver newFromTemplate Availability Dreamweaver 3 Description Creates a new document from the specified template If...

Page 315: ...the file to open which is expressed as a URL If the URL is relative it is relative to the file that contains the script that called this function Returns The document object for the specified file whi...

Page 316: ...which is the same value that the dreamweaver getDocumentDOM function returns dreamweaver openInFrame Availability Dreamweaver 3 Description Opens the Open In Frame dialog box When the user selects a...

Page 317: ...ree which is the value that the dreamweaver getDocumentDOM function returns Returns Nothing dreamweaver revertDocument Availability Dreamweaver 3 Description Reverts the specified document to the prev...

Page 318: ...root of a document s DOM tree which is the value that the dreamweaver getDocumentDOM function returns The fileURL argument which is optional is a URL that represents a location on a local computer If...

Page 319: ...e root of a document s DOM tree which is the value that the dreamweaver getDocumentDOM function returns Returns Nothing dreamweaver saveDocumentAsTemplate Availability Dreamweaver 3 Description Opens...

Page 320: ...the root of a document s DOM tree which is the value that the dreamweaver getDocumentDOM function returns Returns Nothing Enabler See dreamweaver canSaveFrameset on page 572 dreamweaver saveFramesetA...

Page 321: ...n the document dom checkSpelling Availability Dreamweaver 3 Description Checks the spelling in the document opening the Check Spelling dialog box if necessary and notifies the user when the check is c...

Page 322: ...w as HTML Arguments None Returns A string that specifies the current parsing mode html xml css or text dom hideInfoMessagePopup Availability Dreamweaver MX 2004 Description Hides the tooltip like mess...

Page 323: ...dation which underlines errors in the Code view instead of opening the Validation results window see dom source getValidationErrorsForOffset on page 533 and dom getAutoValidationCount on page 525 If t...

Page 324: ...ent toolbar dw getDocumentDOM runValidation auto implicit false dom showInfoMessagePopup Availability Dreamweaver MX 2004 Description Shows a tooltip like message in the document window or under a too...

Page 325: ...tDOM showInfoMessagePopup This message is in the center 5000 dw getDocumentDOM showInfoMessagePopup toolbar DW_Toolbar_Main DW_SetTitle Don t forget the title for the window 5000 See also dom hideInfo...

Page 326: ...Submit Get Directions dreamweaver getElementRef Availability Dreamweaver 2 Description Gets the Netscape Navigator or Internet Explorer object reference for a specific tag object in the DOM tree Argu...

Page 327: ...o tags are specified for all tags in the document and formulates browser specific references to those tags This function is equivalent to calling getElementsByTagName and then calling dreamweaver getE...

Page 328: ...return references for unnamed objects If an object does not contain either a NAME or an ID attribute Dreamweaver returns unnamed tag If the browser does not support a reference by name Dreamweaver ref...

Page 329: ...ce of the requested tag type in the specified document If one of the tag arguments is LAYER the function returns all LAYER and ILAYER tags and all absolutely positioned DIV and SPAN tags If one of the...

Page 330: ...the Snap Distance setting in the My Extension section of Preferences If there is no MyExtension section or no Snap Distance entry the function returns the specified default value of 0 var snapDist def...

Page 331: ...nce setting for an extension This setting is stored with Dreamweaver preferences when Dreamweaver is not running Arguments section key new_value The section argument is a string that specifies the pre...

Page 332: ...exist Dreamweaver creates it The new_value argument is a string that specifies the value of the category option Returns A true value if successful false otherwise Example var txtEditor getExternalText...

Page 333: ...e path to the Dreamweaver Configuration folder which is expressed as a file URL For information on how Dreamweaver accesses Configuration folders on a multiuser platform see C Level Extensibility in E...

Page 334: ...lected document is in a frame and the parent frames number and parent frames frameName values specify a document that is in a particular frame within the frameset that contains the current document Re...

Page 335: ...d as a file URL Example The following line of code returns the full path for the specified file The dw getTempFolderPath function does not return a slash at the end of the path as do other Dreamweaver...

Page 336: ...the combination of docPath relURL If relURL is a root relative URL the return value is the combination of siteRoot relURL Selection functions Selection functions get and set the selection in open doc...

Page 337: ...numbers are the same the current selection is an insertion point For complex selections multiple table cells multiple layers or multiple image map hotspots an array that contains 2n integers where n i...

Page 338: ...offsetsToNode Availability Dreamweaver 3 Description Gets the object in the DOM tree that completely contains the range of characters between the specified opening and closing points It is valid for...

Page 339: ...value to the dom setSelection function Arguments node bSelectInside bJumpToNode The node argument is a text comment or element node in the document The bSelectInside argument which is optional is a B...

Page 340: ...character offsets into the document s source code If the two numbers are the same the new selection is an insertion point If the new selection is not a valid HTML selection it is expanded to include...

Page 341: ...tion lets you confirm that the node hasn t been deleted before you attempt to reference any of its properties or methods The referenced node does not need to be in the current document Arguments node...

Page 342: ...ontains two integers The first integer is the byte offset for the opening of the tag text or comment the second integer is the byte offset for the closing of the node dreamweaver offsetsToNode depreca...

Page 343: ...etBegin offsetEnd These arguments are the opening and closing points respectively for the new selection which is expressed as byte offsets into the document s source code If the two numbers are the sa...

Page 344: ...ns a URL encoded string by replacing all the spaces and special characters with specified entities Arguments stringToConvert The stringToConvert argument is a string that contains the unencoded URL th...

Page 345: ...ed as a single separator Returns An array of token strings Example The following call to the dw getTokens function returns the tokens that come after it dreamweaver getTokens foo my arg1 34 foo my arg...

Page 346: ...ourceString Availability Dreamweaver UltraDev 1 Description Scans a string of HTML and finds the tags attributes directives and text For each tag attribute directive and text span that it finds the sc...

Page 347: ...ple font The function accepts two arguments the name of the tag to close for example font and the document offset which is the number of bytes in the document before the beginning of the closing tag T...

Page 348: ...ise Example The following sequence of steps provide an example of how to use the dreamweaver scanSourceString function 1 Create an implementation for one or more of the seven callback functions 2 Writ...

Page 349: ...ctive document Arguments translatorName The translatorName argument is the name of a translator as it appears in the Translation preferences Returns Nothing dreamweaver editLockedRegions Availability...

Page 350: ...the installed translators Arguments None Returns An array of strings where each string represents the name of a translator as it appears in the Translation preferences dreamweaver useTranslatedSource...

Page 351: ...n Returns Nothing XSLT functions XSLT functions deal with XML files These functions get information about XML documents including the schema tree or the reference to an XML document and prompt the use...

Page 352: ...is optional is a Boolean value true returns a reference to the temporary XML file for example file C Documents and Settings username Local Settings Temporary Internet Files Content IE5 GTSLQ9KZ rss 1...

Page 353: ...example file C Documents and Settings username Local Settings Temporary Internet Files Content IE5 GTSLQ9KZ rss 1 xml that is downloaded when the original XML file is remote for example http myHost rs...

Page 354: ...354 Document...

Page 355: ...ets panel functions which are programmed into the API as an asset panel let you manage and use the elements in the Assets panel templates libraries images Macromedia Shockwave and Macromedia Flash con...

Page 356: ...ot remove the element from the Site list Arguments None Returns Nothing dreamweaver assetPalette addToFavoritesFromSite Window Availability Dreamweaver 4 Description Adds the elements that are selecte...

Page 357: ...Site argument is the name of the target site which the site getSites call returns Returns Nothing dreamweaver assetPalette edit Availability Dreamweaver 4 Description Edits selected elements with prim...

Page 358: ...the selected items in the Assets panel either in the Site or Favorites list Arguments None Returns An array of the following three strings for each selected item The name string which is the name file...

Page 359: ...lectedView Availability Dreamweaver 4 Description Indicates which list is currently shown in the Assets panel Arguments None Returns Returns a string that has a value of either site or favorites dream...

Page 360: ...folder is selected in the Favorites list the folder is ignored Arguments None Returns Nothing dreamweaver assetPalette newAsset Availability Dreamweaver 4 Description Creates a new element for the cur...

Page 361: ...setPalette recreateLibraryFromDoc ument Availability Dreamweaver 4 Description Replaces the deprecated libraryPalette function recreateLibraryFromDocument It creates a Library item LBI file for the se...

Page 362: ...ry or template where the user is prompted before the file is deleted It works only in the Favorites list or if the category is Library or Templates Arguments None Returns Nothing dreamweaver assetPale...

Page 363: ...s Returns Nothing dreamweaver assetPalette setSelectedView Availability Dreamweaver 4 Description Switches the display to show either the Site list or the Favorites list Arguments viewType The viewTyp...

Page 364: ...eamweaver 3 deprecated in 4 in favor of dreamweaver assetPalette getSelectedItems Description This function gets the path of the selected library item Arguments None Returns A string that contains the...

Page 365: ...ion This function creates an LBI file for the selected instance of a library item in the current document This function is equivalent to clicking Recreate in the Property inspector Arguments None Retu...

Page 366: ...the Reference panel display region Arguments None Returns The relative font size as small medium or large dreamweaver referencePalette setFontSize Availability Dreamweaver 4 Description Changes the fo...

Page 367: ...assetPalette removeFromFavorites Description This function deletes the selected template from the Templates folder Arguments None Returns Nothing dreamweaver templatePalette getSelected Template depr...

Page 368: ...let you add behaviors to and remove them from an object find out which behaviors are attached to an object get information about the object to which a behavior is attached and so on Methods of the dre...

Page 369: ...ption 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 eve...

Page 370: ...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 event...

Page 371: ...ample The dreamweaver getBehaviorElement function can be used in the same way as dreamweaver getBehaviorTag to determine whether the selected action is appropriate for the selected HTML tag except tha...

Page 372: ...the tag to which the behavior is being applied This function is applicable only in action files Arguments None Returns A string that represents the source of the tag This is the same string that passe...

Page 373: ...ons folder that contains a JavaScript behavior action for example Timeline Play Timeline htm The funcCall argument which is optional is a string that contains a function call for the action that is sp...

Page 374: ...o items An event handler A function call or JavaScript statement Example Because positionIndex is a zero based index if the Behaviors panel displays the list a call to the dreamweaver behaviorInspecto...

Page 375: ...ookie onClick MM_popupMsg A cookie has been set parent rightframe location href aftercookie html returns 2 dreamweaver behaviorInspector getSelectedBehavior Availability Dreamweaver 3 Description Gets...

Page 376: ...at position 0 Returns Nothing Example If the Behaviors panel is set up as shown in the following figure calling the dreamweaver behaviorInspector moveBehaviorDown 2 function swaps the positions of the...

Page 377: ...s at position 0 Returns Nothing Example If the Behaviors panel is set up as shown in the following figure calling the dreamweaver behaviorInspector moveBehaviorUp 3 function swaps the positions of the...

Page 378: ...e action in the Behaviors panel The first action in the list is at position 0 To deselect all actions specify a positionIndex of 1 Specifying a position for which no action exists is equivalent to spe...

Page 379: ...in the active window the current Document window the Code inspector or the Site panel On the Macintosh the function can also operate on the selection in a text box if it is the current field The DOM v...

Page 380: ...he selection to the Clipboard Arguments None Returns Nothing dom clipPaste Availability Dreamweaver 3 Description Pastes the contents of the Clipboard into the current document at the current insertio...

Page 381: ...aver 8 Use the dom clipPaste text function instead Description Pastes the contents of the Clipboard into the current document at the insertion point or in place of the current selection It replaces an...

Page 382: ...lipPasteText results in the following figure dreamweaver clipCopy Availability Dreamweaver 3 Description Copies the current selection from the active Document window dialog box floating panel or Site...

Page 383: ...on page 565 dreamweaver clipPaste Availability Dreamweaver 3 Added the strPasteOption argument in Dreamweaver 8 Description Pastes the contents of the Clipboard into the current document dialog box fl...

Page 384: ...ontains the contents of the Clipboard if the Clipboard contains text which can be HTML otherwise it returns nothing Example If dreamweaver getClipboardText returns text b bold b text dreamweaver getCl...

Page 385: ...the current site which is expressed as a file URL The bMaintainLink argument is a Boolean value that indicates whether to maintain the link to the original template true or not false Returns Nothing E...

Page 386: ...tAttachedTemplate Availability Dreamweaver 3 Description Gets the path of the template that is associated with the document Arguments None Returns A string that contains the path of the template which...

Page 387: ...nes whether the document is a library item Arguments None Returns A Boolean value that indicates whether the document is an LBI file dom getIsTemplateDocument Availability Dreamweaver 3 Description De...

Page 388: ...m getEditableRegionList on page 386 Example The following code shows a dialog box with the contents of the selected editable region var theDOM dw getDocumentDOM var edRegs theDOM getEditableRegionList...

Page 389: ...ge any text Arguments None Returns Nothing Enabler See dom canMarkSelectionAsEditable on page 559 dom newEditableRegion Availability Dreamweaver 3 Description Displays the New Editable Region dialog b...

Page 390: ...arkers are removed Arguments None Returns Nothing Enabler See dom canRemoveEditableRegion on page 560 dom updateCurrentPage Availability Dreamweaver 3 Description Updates the document s library items...

Page 391: ...Using Dreamweaver web developers can edit and save reusable blocks of code in the Snippets panel and retrieve them as needed The Snippets panel stores each code snippet in a CSN file within the Confi...

Page 392: ...nippetPalette getCurrentSnippetPath Availability Dreamweaver MX 2004 Description Returns the path to the snippet that is currently selected in the Snippets panel Arguments None Returns The path relati...

Page 393: ...fault name Arguments None Returns Nothing dreamweaver snippetPalette newSnippet Availability Dreamweaver MX Description Opens the Add Snippet dialog box and gives it focus Arguments None Returns Nothi...

Page 394: ...the current selection Arguments None Returns Nothing Enabler See dreamweaver snippetpalette canInsert on page 585 dreamweaver snippetPalette insertSnippet Availability Dreamweaver MX Description Inse...

Page 395: ...rtSnippet Text Different_Link_Color csn dreamweaver snippetPalette rename Availability Dreamweaver MX Description Activates a text box around the selected folder name or file nickname and lets you edi...

Page 396: ...396 Page Content...

Page 397: ...er behavior to a document or getting the names of all currently defined server models Server Components functions Server Components functions let you access the currently selected node of the Server C...

Page 398: ...ociated with the data sources for that server model For more information about using data sources in Dreamweaver see Data Sources in Extending Dreamweaver dreamweaver dbi getDataSources Availability D...

Page 399: ...ks on the item as if the property is set to a value of true The dataSource property is the simple name of the file in which the findDynamicSources function is defined For example the findDynamicSource...

Page 400: ...value If a value is not specified Dreamweaver uses the default value Example The following example retrieves the location attribute value for the insertText tag of the recordset_main participant dw g...

Page 401: ...r expects an array of participant names that have the specified property if it is given and the property matches the specified value if it is given dreamweaver getExtGroups Availability Dreamweaver Ul...

Page 402: ...aDialog function is used for the View Live Data Settings menu item The setLiveDataMode function is used for the View Live Data and View Refresh Live Data menu items The getLiveDataMode function determ...

Page 403: ...lateMarkup function so that the translator can pass the tags to the liveDataTranslate function Arguments None Returns A string that contains the initialization tags dreamweaver getLiveDataMode Availab...

Page 404: ...alog box which you can activate from the View menu In the URL text field that appears at the top of the document when you click the Live Data View button on the toolbar For the ID and Name parameters...

Page 405: ...re source code of the user s document It is the same string that is used in the next operation Saves the HTML string from the user s document as a temporary file on the live data server Sends an HTTP...

Page 406: ...appears after the liveDataTranslateMarkup function finishes executing Dreamweaver displays the description in an error dialog box The setLiveDataError function should be called only from the liveDataT...

Page 407: ...any URL parameters that you reference in your document This prevents the web server from returning errors for parameters that are otherwise undefined in the simulation You enter the URL parameters in...

Page 408: ...ev 4 Description The JavaScript function dreamweaver getParticipants gets a list of participants from the user s document After Dreamweaver finds all the behavior s participants it stores those lists...

Page 409: ...t node of the document to the beginning of the participant content The matchRangeMax property is an integer of the participant that defines the offset from the beginning of the participant node to the...

Page 410: ...s for the behavior Returns Nothing Server model functions In Macromedia Dreamweaver each document has an associated document type For dynamic document types Dreamweaver also associates a server model...

Page 411: ...folder Arguments None Returns A string which holds the URL to the application server that is used for live data and debugging purposes Example If the user creates a site and specifies that the testin...

Page 412: ...d in the listed delimiters should true or should not false participate in block merging dom serverModel getDisplayName Availability Dreamweaver MX Description Gets the name of the server model that ap...

Page 413: ...ly selected site Arguments None Returns A string that represents the supported file extensions dom serverModel getServerIncludeUrlPatterns Availability Dreamweaver MX Description Returns the following...

Page 414: ...ludeArray serverModel getServerIncludeUrlPatterns The call to serverModel getServerIncludeUrlPatterns returns the following three properties dom serverModel getServerInfo Availability Dreamweaver MX D...

Page 415: ...rModel getServerLanguage deprecated Availability UltraDev 1 deprecated in Dreamweaver MX Description Determines the server model that is associated with the document and returns that value The server...

Page 416: ...uages on the same server technology such as ASP NET VB and ASP NET C Possible values include ASP ASP NET Cold Fusion JSP and PHP To retrieve the server model name associated with the document see dom...

Page 417: ...th the document and returns that value Each server model has a getVersionArray function as defined in the Server Models API which returns a table of name version pairs N OT E In addition to letting yo...

Page 418: ...er can be made Arguments None Returns A Boolean value that indicates whether the request to connect to the application server was successful dreamweaver getServerModels Availability Dreamweaver MX Des...

Page 419: ...ng removing creating and deleting CSS styles Methods of the dreamweaver cssRuleTracker object either control or act on the selection in the CSS rule tracker panel of the Selection inspector Methods of...

Page 420: ...xplorerRendering argument which is required indicates whether to render for Internet Explorer true or to render for the CSS specification false Returns Nothing Example See cssStylePalette getInternetE...

Page 421: ...a false value if it is not specified Returns Nothing Example The following code applies the red style to the selection either by surrounding the selection with SPAN tags or by applying a CLASS attribu...

Page 422: ...ull dom getShowDivBackgrounds Availability Dreamweaver 8 Description This function gets the state of the Layout Block Backgrounds visual aid Arguments None Returns A Boolean true if the Layout Block B...

Page 423: ...del false currentDOM setShowDivBoxModel true dom getShowDivOutlines Availability Dreamweaver 8 Description This function gets the state of the Layout Block Outlines visual aid Arguments None Returns A...

Page 424: ...uld be removed either class or id If the classOrID argument is not specified it defaults to class If no CLASS attribute is defined for the elementNode argument the SPAN tag that surrounds the elementN...

Page 425: ...rguments view The view argument which is required is a string that sets the currently selected element to full or hidden If the currently selected element is normal the setElementView function looks f...

Page 426: ...ns the Layout Block Backgrounds visual aid on Returns Nothing Example See dom getShowDivBackgrounds on page 422 dom setShowDivBoxModel Availability Dreamweaver 8 Description This function turns the La...

Page 427: ...e turns the Layout Block Outlines visual aid on Returns Nothing Example See dom getShowDivOutlines on page 423 dreamweaver cssRuleTracker editSelectedRule Availability Dreamweaver MX 2004 Description...

Page 428: ...tion in the Styles panel Arguments pane The pane argument which is optional is a string that specifies the pane of the Styles Panel to which this function applies Possible values are stylelist which i...

Page 429: ...currently selected in the Styles panel from the document Arguments pane The pane argument which is optional is a string that specifies the pane of the Styles Panel to which this function applies Possi...

Page 430: ...ssible values are stylelist which is the list of styles in All mode cascade which is the list of applicable relevant rules in Current mode summary which is the list of properties for the current selec...

Page 431: ...cssStylePalette editSelectedStyleInCo deview Availability Dreamweaver 8 Description Ths function switches to Code view and moves the mouse pointer to the code for the style that is currently selected...

Page 432: ...on page 578 dreamweaver cssStylePalette getDisplayStyles Availability Dreamweaver 8 Description This function determines whether CSS styles are being rendered The default value is true Arguments None...

Page 433: ...selector that means the style is applied to any p tag of class1 but it does not apply for instance to a div tag of class1 Without the fullSelector argument the dreamweaver cssStylePalette getSelectedS...

Page 434: ...tive document Without arguments it just returns class selector names If the bGetIDs argument is true it returns just ID selector names In either case if the bGetFullSelector argument is true it return...

Page 435: ...tor string instead of just the names Defaults to false Returns An array of strings that represent the names of all the class styles in the document Example If the Styles panel is set up as shown in th...

Page 436: ...de which is the list of applicable relevant rules in Current mode summary which is the list of properties for the current selection in Current mode and ruleInspector which is the editable list or grid...

Page 437: ...ent specifies the new target media type Returns Nothing Example dw cssStylePalette setMediaType print dreamweaver getBlockVisBoxModelColors Availability Dreamweaver 8 Description This function gets th...

Page 438: ...layers If the forWhat argument is divs the function returns the properties used for the visual aid that outlines all layout blocks If forWhat is selectedDiv the function returns the property used for...

Page 439: ...n This function sets the outline properties for the block visualization visual aids Arguments forWhat color width style The forWhat argument which is required is a string that specifies for what the s...

Page 440: ...s used by the Layout Block Backgrounds visual aid Arguments colors The colors argument which is required is an array of strings that contains all the colors represented as hexadecimal values in the fo...

Page 441: ...set Arguments None Returns An array of strings where each string is the name of a frame in the current frameset Any unnamed frames are skipped If none of the frames in the frameset is named an empty a...

Page 442: ...nt window If the specified document is not in a frameset this function saves the document This function opens the Save As dialog box for any documents that have not been previously saved Arguments Non...

Page 443: ...3 Description Aligns the selected layers or hotspots left right top or bottom Arguments alignDirection The alignDirection argument is a string that specifies the edge to align with the layers or hots...

Page 444: ...ates whether to resize the layers or hotspots horizontally The bVert argument is a Boolean value that indicates whether to resize the layers or hotspots vertically Returns Nothing dom moveSelectionBy...

Page 445: ...ayer or hotspot The bottom argument is the new position of the bottom boundary of the layer or hotspot The right argument is the new position of the right boundary of the layer or hotspot Returns Noth...

Page 446: ...get and set the ruler origin and units turn the grid on and off and change its settings and start or stop playing plug ins dom getRulerOrigin Availability Dreamweaver 3 Description Gets the origin of...

Page 447: ...document s tracing image Arguments None Returns A value between 0 and 100 or nothing if no opacity is set Enabler See dom hasTracingImage on page 563 dom loadTracingImage Availability Dreamweaver 3 De...

Page 448: ...in the document Arguments None Returns Nothing dom playPlugin Availability Dreamweaver 3 Description Plays the selected plug in item Arguments None Returns Nothing Enabler See dom canPlayPlugin on pa...

Page 449: ...e current ruler units Arguments units The units argument must be px in or cm Returns Nothing dom setTracingImagePosition Availability Dreamweaver 3 Description Moves the upper left corner of the traci...

Page 450: ...ment must be a number between 0 and 100 Returns Nothing Enabler See dom hasTracingImage on page 563 Example The following code sets the opacity of the tracing image to 30 dw getDocumentDOM setTracingO...

Page 451: ...s all plug in content that is currently playing in the document Arguments None Returns Nothing dom stopPlugin Availability Dreamweaver 3 Description Stops the selected plug in item Arguments None Retu...

Page 452: ...Dreamweaver 3 Description Moves the visible floating panels to their default positions Arguments None Returns Nothing dreamweaver showGridSettingsDialog Availability Dreamweaver 3 Description Opens t...

Page 453: ...is created Returns Nothing dom createLayoutCell Availability Dreamweaver 4 Description Creates a layout cell in the current document at the specified position and dimensions either within an existing...

Page 454: ...bles but it can contain other layout cells or nested layout tables This function does not force the document into Layout view This function fails if the table cannot be created Arguments left top widt...

Page 455: ...images that Dreamweaver generated It fails if the current selection is not a table Arguments None Returns Returns true if the table contains a row of spacer images false otherwise dom getClickedHeade...

Page 456: ...dom getShowLayoutView Availability Dreamweaver 4 Description Determines the view for the current document either Layout or Standard view Arguments None Returns Returns true if the current document is...

Page 457: ...selected table this function sets the width of each column in the HTML to match the currently rendered width of the column This function fails if the current selection is not a table or if the operat...

Page 458: ...ColumnAutostretch Availability Dreamweaver 4 Description Switches a column between automatically sized or fixed width If bAutostretch is true the column at the given index in the currently selected ta...

Page 459: ...are not being forced Example The following example checks whether the background coloring for all blocks is being forced and if not forces background coloring for all blocks var currentDOM dw getDocum...

Page 460: ...n gets the state of the visual aid that displays ID and class information for all blocks or divs Arguments allblocks The allblocks argument which is required is a Boolean Set the value to true to disp...

Page 461: ...nd if not colors it var currentDOM dw getDocumentDOM if currentDOM getShowBoxModel false currentDOM setShowBoxModel true dom setShowBlockBackgrounds Availability Dreamweaver 8 Description This functio...

Page 462: ...div tags only Set the value to false to apply borders to all block elements Returns Nothing Example See dom getShowBlockBorders on page 459 dom setShowBlockIDs Availability Dreamweaver 8 Description T...

Page 463: ...l is not displayed Example See dom getShowBoxModel on page 461 dom setShowLayoutTableTabs Availability Dreamweaver 4 Description Sets the current document to display tabs for layout tables whenever it...

Page 464: ...Design view dreamweaver activeViewScale Availability Dreamweaver 8 Description This function gets or sets a mutable floating point property When you get the value Dreamweaver returns the active view...

Page 465: ...or out so that the entire document fits in the currently visible portion of the Design view Arguments None Returns Nothing Enabler See dreamweaver canZoom on page 574 Example if canZoom fitAll dreamwe...

Page 466: ...ument width fits in the currently visible portion of the Design view Arguments None Returns Nothing Enabler See dreamweaver canZoom on page 574 Example if canZoom fitWidth dreamweaver zoomIn Availabil...

Page 467: ...oomOut Availability Dreamweaver 8 Description This function zooms out on the currently active Design view The zoom level is the next preset value in the Magnification menu If there is no next preset v...

Page 468: ...tion determines whether to delete all guides in the document Arguments None Returns Nothing Example The following example deletes all guides in the document if the document has at least one guide var...

Page 469: ...currentDOM createHorizontalGuide 10px dom createVerticalGuide Availability Dreamweaver 8 Description This function creates a vertical guide at the current location in the document Arguments location...

Page 470: ...Nothing Example The following example deletes the horizontal guide at the specified location in the document var currentDOM dw getDocumentDOM if currentDOM hasHorizontalGuide 10px true currentDOM del...

Page 471: ...weaver 8 Description This mutable color property determines the color of guides in the document You can set and get this property Arguments None Returns Nothing Example The following example makes gui...

Page 472: ...entDOM guidesDistanceColor CCCCCC dom guidesLocked Availability Dreamweaver 8 Description This mutable Boolean property determines whether guides are locked in the document You can set and get this pr...

Page 473: ...rguments None Returns Nothing Example The following example makes guides in the document snap to elements var currentDOM dw getDocumentDOM if currentDOM guidesSnapToElements false currentDOM guidesSna...

Page 474: ...whether the document has at least one guide You can set and get this property Arguments None Returns Nothing Example The following example deletes all guides in the document if the document has at le...

Page 475: ...document has a horizontal guide at the specified location var currentDOM dw getDocumentDOM if currentDOM hasHorizontalGuide 10px true currentDOM clearGuides dom hasVerticalGuide Availability Dreamwea...

Page 476: ...true currentDOM clearGuides dom snapToGuides Availability Dreamweaver 8 Description This mutable Boolean property determines whether elements snap to guides in the document You can set and get this pr...

Page 477: ...ther standard table editing tasks dom convertWidthsToPercent Availability Dreamweaver 3 Description This function converts all WIDTH attributes in the current table from pixels to percentages Argument...

Page 478: ...eases the column span by one Arguments None Returns Nothing Enabler See dom canDecreaseColspan on page 554 dom decreaseRowspan Availability Dreamweaver 3 Description This function decreases the row sp...

Page 479: ...es the selected table column or columns Arguments None Returns Nothing Enabler See dom canDeleteTableColumn on page 555 dom deleteTableRow Availability Dreamweaver 3 Description This function removes...

Page 480: ...t if the Faster Table Editing option is not selected Arguments None Returns Nothing dom getShowTableWidths Availability Dreamweaver MX 2004 Description Returns whether table widths appear in standard...

Page 481: ...The first array item is the number of columns and the second array item is the number of rows If no table is selected nothing returns dom increaseColspan Availability Dreamweaver 3 Description This f...

Page 482: ...fCols bBeforeSelection The numberOfCols argument is the number of columns to insert The bBeforeSelection argument is a Boolean value true indicates that the columns should be inserted before the colum...

Page 483: ...that contains the selection false otherwise Returns Nothing Enabler See dom canInsertTableRows on page 558 dom mergeTableCells Availability Dreamweaver 3 Description This function merges the selected...

Page 484: ...DTH attributes from the selected table Arguments None Returns Nothing dom removeColumnWidth Availability Dreamweaver MX 2004 Description This function removes all WIDTH attributes from a single select...

Page 485: ...otherwise specified For information on setting the display of table tabs in Layout mode see dom setShowLayoutTableTabs on page 463 Arguments bShow The bShow is a Boolean argument that indicates whethe...

Page 486: ...umns in the selected table Arguments numberOfCols The numberOfCols argument specifies the number of columns to set in the table Returns Nothing dom setTableRows Availability Dreamweaver 3 Description...

Page 487: ...ll Availability Dreamweaver 3 Description This function splits the current table cell into the specified number of rows or columns If one or both of the arguments is omitted the Split Cells dialog box...

Page 488: ...488 Design...

Page 489: ...names Instead of typing the rest of the tag name you can select the tag from the menu to include it in your text You can add Code Hints menus to Dreamweaver by defining them in the CodeHints xml file...

Page 490: ...pop up menu The valueArray argument which is optional is an array of strings which should be the same length as the labelArray argument When a user selects an item from the pop up menu the string in t...

Page 491: ...user types myRS new Array firstName lastName items in drop down menu for myRS new Array firstName lastName text to actually insert in document null no icons for this menu ASP_VB ASP_JS specific to the...

Page 492: ...e only for JSP document types dw codeHints addFunction CodeHints_Object_Methods out newLine JSP dreamweaver codeHints resetMenu Availability Dreamweaver MX Description Resets the specified menu tag or...

Page 493: ...les dreamweaver codeHints showCodeHints Availability Dreamweaver MX Description Dreamweaver calls this function when the user opens the Edit Show Code Hints menu item The function opens the Code Hints...

Page 494: ...or by the user in the Find dialog box and selects the instance in the document Arguments bUseLastSetupSearch The bUseLastSetupSearch argument which is optional is a Boolean value If bUseLastSetupSearc...

Page 495: ...the function then replaces the selection with the replacement text that is specified by the search request Arguments None Returns Nothing dreamweaver replaceAll Availability Dreamweaver 3 Description...

Page 496: ...uery tag to the closing of the dwquery tag Returns Nothing Example The first line of the following example sets up a tag search and specifies that the scope of the search should be the current documen...

Page 497: ...mweaver setUpComplexFindReplace dwquery queryparams matchcase false ignorewhitespace true useregexp false find qtag qname a qattribute qname href qcompare qvalue qattribute qattribute qname onMouseOut...

Page 498: ...alse Returns Nothing Example The following code demonstrates three ways to create a searchObject object var searchParams searchParams searchString bgcolor FFCCFF searchParams searchSource true dreamwe...

Page 499: ...false The useRegularExpressions property is a Boolean value that indicates whether the searchString property uses regular expressions If this property is not explicitly set it defaults to a value of...

Page 500: ...573 General editing functions You handle general editing functions in the Document window These functions insert text HTML and objects apply change and remove font and character markup modify tags an...

Page 501: ...Availability Dreamweaver 3 Description Applies the FONT tag and the specified attribute and value to the current selection Arguments attribute value The attribute argument must be face size or color T...

Page 502: ...ive document Arguments attribute The attribute is a string that specifies the tag attribute that you want to edit Returns Nothing dom exitBlock Availability Dreamweaver 3 Description Exits the current...

Page 503: ...he attribute argument must be face size or color Returns A string that contains the value of the specified attribute or an empty string if the attribute is not set dom getLineFromOffset Availability D...

Page 504: ...that contains the name of the linked file which is expressed as a file URL dom getLinkTarget Availability Dreamweaver 3 Description Gets the target of the link that surrounds the current selection Th...

Page 505: ...ays returns in lowercase letters dom getTextAlignment Availability Dreamweaver 3 Description Gets the alignment of the block that contains the selection Arguments None Returns A string that contains t...

Page 506: ...f the tag that you re checking It must be one of the following strings b cite code dfn em i kbd samp s strong tt u or var Returns A Boolean value that indicates whether the entire selection has the sp...

Page 507: ...nt which is optional is a Boolean value that indicates whether the content should replace the current selection If the bReplaceCurrentSelection argument is a value of true the content replaces the cur...

Page 508: ...t content into the document at the current insertion point Arguments contentToInsert bReplaceCurrentSelection The contentToInsert argument is the content that you want to insert The bReplaceCurrentSel...

Page 509: ...w as shown in the following figure dom newBlock Availability Dreamweaver 3 Description Creates a new block with the same tag and attributes as the block that contains the current selection or creates...

Page 510: ...ratio from the original size For example Flash Text uses this feature to update the text in the Layout view as the user changes its properties in the Command dialog box Arguments None Returns Nothing...

Page 511: ...Nothing dom removeFontMarkup Availability Dreamweaver 3 Description Removes the specified attribute and its value from a FONT tag If removing the attribute leaves only the FONT tag the FONT tag is al...

Page 512: ...ction will set the selected object Returns Nothing dom setAttributeWithErrorChecking Availability Dreamweaver 3 Description Sets the specified attribute to the specified value for the current selectio...

Page 513: ...Nothing Enabler See dom canSetLinkHref on page 561 dom setLinkTarget Availability Dreamweaver 3 Description Sets the target of the link that surrounds the current selection This function is equivalent...

Page 514: ...rgument must be either menu or list box Returns Nothing dom showListPropertiesDialog Availability Dreamweaver 3 Description Opens the List Properties dialog box Arguments None Returns Nothing Enabler...

Page 515: ...Dreamweaver 3 Description Sets the ALIGN attribute of the block that contains the selection to the specified value Arguments alignValue The alignValue argument must be left center or right Returns Not...

Page 516: ...ats for no format p h1 h2 h3 h4 h5 h6 or pre Returns Nothing dom showFontColorDialog Availability Dreamweaver 3 Description Opens the Color Picker dialog box Arguments None Returns Nothing dreamweaver...

Page 517: ...eamweaver 3 Description Opens the Edit Font List dialog box Arguments None Returns Nothing dreamweaver getFontList Availability Dreamweaver 3 Description Gets a list of all the font groups that appear...

Page 518: ...amweaver 4 Description Returns the styles that a specified TrueType font supports Arguments fontName The fontName argument is a string that contains the name of the font Returns An array of three Bool...

Page 519: ...n operation if dw getKeyState Shift dw getKeyState Cmd execute code dreamweaver getNaturalSize Availability Dreamweaver 4 Description Returns the width and height of a graphical object Arguments url T...

Page 520: ...weaver printCode Availability Dreamweaver MX Description In Windows this function prints all or selected portions of code from the Code view On the Macintosh it prints all code or a page range of code...

Page 521: ...t request var theDOM dreamweaver getDocumentDOM document if dreamweaver PrintCode true theDOM alert Unable to execute your print request Quick Tag Editor functions Quick Tag Editor functions navigate...

Page 522: ...w Arguments None Returns Nothing dom stripTag Availability Dreamweaver 3 Description Removes the tag from around the current selection leaving any contents If the selection has no tags or contains mor...

Page 523: ...ver showQuickTagEditor Availability Dreamweaver 3 Description Displays the Quick Tag Editor for the current selection Arguments nearWhat mode The optional nearWhat argument if specified must be either...

Page 524: ...the settings in the Preferences Code Format dialog box Arguments startOffset endOffset The startOffset argument is an integer that represents the beginning of the specified range as the offset from t...

Page 525: ...ationCount Availability Dreamweaver MX 2004 Description Gets the number of errors warnings and information messages for the last auto validation also known as an inline validation of the document Curr...

Page 526: ...perations that require a valid document state Arguments None Returns A Boolean value true if the Design view WYSIWYG is synchronized with the text in the Text view false otherwise dom isSelectionValid...

Page 527: ...e rendered true if the noscript tag content should be rendered false otherwise Returns Nothing dom source arrowDown Availability Dreamweaver 4 Description Moves the insertion point down the Code view...

Page 528: ...er content is being selected If bShiftIsDown is true the content is selected Returns Nothing dom source arrowRight Availability Dreamweaver 4 Description Moves the insertion point to the right in the...

Page 529: ...lue that indicates whether content is being selected If bShiftIsDown is true the content is selected Returns Nothing dom source balanceBracesTextview Availability Dreamweaver 4 Description This functi...

Page 530: ...hat indicates whether content is being selected If bShiftIsDown is true the content is selected Returns Nothing dom source endOfLine Availability Dreamweaver 4 Description Places the insertion point a...

Page 531: ...he nTimes argument which is optional is the number of pages that the insertion point must move If nTimes is omitted the default is 1 The bShiftIsDown argument which is optional is a Boolean value that...

Page 532: ...the closing of the selection If the two numbers are equal the selection is an insertion point If there is no selection in the source both numbers are 1 dom source getLineFromOffset Availability Dreamw...

Page 533: ...ment which is optional is a string that specifies empty forward or back If specified the function searches forward or back from the given offset to the next characters with errors and returns them If...

Page 534: ...ors 0 message dom source indentTextview Availability Dreamweaver 4 Description Moves selected Code view text one tab stop to the right Arguments None Returns Nothing dom source insert Availability Dre...

Page 535: ...n to the right Arguments nTimes bShiftIsDown The nTimes argument which is optional is the number of words that the insertion point must move If nTimes is omitted the default is 1 The bShiftIsDown argu...

Page 536: ...ndicates whether content is being selected If bShiftIsDown is true the content is selected Returns Nothing dom source pageUp Availability Dreamweaver 4 Description Moves the insertion point up the Cod...

Page 537: ...s Nothing dom source replaceRange Availability Dreamweaver 4 Description Replaces the range of source text between startOffset and endOffset with string If startOffset is greater than endOffset or if...

Page 538: ...e bottom of the document file without moving the insertion point Arguments None Returns Nothing dom source scrollLineDown Availability Dreamweaver 4 Description Scrolls the Code view down line by line...

Page 539: ...omitted the default is 1 Returns Nothing dom source scrollPageDown Availability Dreamweaver 4 Description Scrolls the Code view down page by page without moving the insertion point Arguments nTimes T...

Page 540: ...insertion point Arguments None Returns Nothing dom source selectParentTag Availability Dreamweaver 4 Description This function is a Code view extension that enables tag balancing You can call dom sour...

Page 541: ...ts lineNumber The lineNumber argument is the line at the beginning of which the insertion point is placed Returns A Boolean value true if successful false otherwise dom source startOfDocument Availabi...

Page 542: ...m source topPage Availability Dreamweaver 4 Description Moves the insertion point to the top of the current page or to the top of the previous page if the insertion point is already at the top of a pa...

Page 543: ...tion was an insertion point then the function places the insertion point between the startTag and endTag startTag and endTag don t have to be tags they can be any arbitrary text Arguments startTag end...

Page 544: ...braries in your extensions dom getTagSelectorTag Availability Dreamweaver MX Description This function gets the DOM node for the tag that is currently selected in the Tag Selector bar at the bottom of...

Page 545: ...mweaver MX Description If a tag is selected this function opens the tag editor for that tag so you can edit the tag Arguments None Returns Nothing Enabler See dreamweaver canPopupEditTagDialog on page...

Page 546: ...URL of a filename vtm file this function returns the DOM for that file so that its contents can be edited This function should be called only when the Tag Library editor is active Arguments fileURL T...

Page 547: ...e of the library that is currently selected in the Tag Library editor returns an empty string if no library is selected dreamweaver tagLibrary getSelectedTag Availability Dreamweaver MX Description If...

Page 548: ...tag library dreamweaver tagLibrary getImportedTagList Availability Dreamweaver MX Description This function generates a list of tagInfo objects from an imported tag library Arguments libname The libn...

Page 549: ...a var libName dw tagLibrary importDTDOrSchema fileURL prefix get the array of tags for this library this is the TagInfo object var tagArray dw tagLibrary getImportedTagList libName now I have an array...

Page 550: ...550 Code...

Page 551: ...r the descriptions are not intended to be comprehensive and might exclude some cases in which the function would return a false value Enablers The enabler functions in the JavaScript API include the f...

Page 552: ...document is not a library item or a template and that the selection is not within the NOFRAMES tag dom canArrange Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform a Bring...

Page 553: ...eamweaver can perform a Paste operation Arguments None Returns A Boolean value true if the Clipboard contains any content that can be pasted into Dreamweaver false otherwise dom canClipPasteText Avail...

Page 554: ...otherwise dom canConvertTablesToLayers Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform a Convert Tables to Layers operation Arguments None Returns A Boolean value true i...

Page 555: ...rm a Decrease Rowspan operation Arguments None Returns A Boolean value true if the current cell has a ROWSPAN attribute and that attribute s value is greater than or equal to 2 false otherwise dom can...

Page 556: ...or row is selected false otherwise site canEditColumns Description Checks whether a site exists Arguments None Returns A Boolean value true if a site exists false otherwise dom canEditNoFramesContent...

Page 557: ...t of the current cell false otherwise dom canIncreaseRowspan Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform an Increase Rowspan operation Arguments None Returns A Boolea...

Page 558: ...eamweaver can perform an Insert Row s operation Arguments None Returns A Boolean value true if the selection is inside a table false if the selection is an entire table or is not inside a table dom ca...

Page 559: ...t is a DWT file false otherwise dom canMergeTableCells Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform a Merge Cells operation Arguments None Returns A Boolean value true...

Page 560: ...olean value true if any steps remain to redo false otherwise dom canRemoveEditableRegion Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform an Unmark Editable Region operati...

Page 561: ...necessary Arguments None Returns A Boolean value true if the selection is an image text or if the insertion point is inside a link false otherwise A text selection is defined as a selection for which...

Page 562: ...thin a frame false otherwise dom canSplitTableCell Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform a Split Cell operation Arguments None Returns A Boolean value true if t...

Page 563: ...tion Arguments None Returns A Boolean value true if any steps remain to undo false otherwise dom hasTracingImage Availability Dreamweaver 3 Description Checks whether the document has a tracing image...

Page 564: ...or applied Returns either a true or false value so the menu items can be enabled or disabled for insertion or application Arguments None Returns Returns a Boolean value true if the selected elements...

Page 565: ...Boolean value true if there is any selected content that can be cut to the Clipboard false otherwise dreamweaver canClipPaste Availability Dreamweaver 3 Description Checks whether Dreamweaver can per...

Page 566: ...nel Arguments None Returns A Boolean value true if the opening and closing offsets for the selection are different which indicates that there is a selection false if the offsets are the same indicatin...

Page 567: ...canExportTemplateDataAsXML to determine whether Dreamweaver can export the current document as XML and if it returns true calls dw ExportTemplateDataAsXML to export it if dreamweaver canExportTemplate...

Page 568: ...selection in an active Design view false otherwise dreamweaver canOpenInFrame Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform an Open in Frame operation Arguments None Re...

Page 569: ...eamweaver can perform a Play Recorded Command operation Arguments None Returns A Boolean value true if there is an active document and a previously recorded command that can be played false otherwise...

Page 570: ...ecks whether Dreamweaver can perform a Revert to the last saved version operation Arguments documentObject The documentObject argument is the object at the root of a document s DOM tree the value that...

Page 571: ...e value that the dreamweaver getDocumentDOM function returns Returns A Boolean value that indicates whether the document has any unsaved changes dreamweaver canSaveDocumentAsTemplate Availability Drea...

Page 572: ...OM function returns Returns A Boolean value that indicates whether the document is a frameset with unsaved changes dreamweaver canSaveFramesetAs Availability Dreamweaver 3 Description Checks whether D...

Page 573: ...aver canShowFindDialog Availability Dreamweaver 3 Description Checks whether Dreamweaver can perform a Find operation Arguments None Returns A Boolean value that is true if a Site panel or a Document...

Page 574: ...lue true if there is an active Design view false otherwise dreamweaver cssRuleTracker canEditSelectedRule Availability Dreamweaver MX 2004 Description Checks whether the Property Grid editor can be ap...

Page 575: ...pecifies the pane of the Styles Panel to which this function applies Possible values are stylelist which is the list of styles in All mode cascade which is the list of applicable relevant rules in Cur...

Page 576: ...e otherwise dreamweaver cssStylePalette canDuplicateSelected Style Availability Dreamweaver MX Description Checks the current active document to see whether the selected style can be duplicated Argume...

Page 577: ...perties in Current mode The default value is stylelist Returns A Boolean value true if the selected style is editable false otherwise dreamweaver cssStylePalette canEditSelectedStyleIn Codeview Availa...

Page 578: ...er cssStylePalette canRenameSelected Style Availability Dreamweaver MX Description Checks the current active document to see whether the selected style can be renamed Arguments pane The pane argument...

Page 579: ...mweaver 3 Description Checks whether Dreamweaver can edit delete or duplicate the selection in the HTML Styles panel Arguments None Returns A Boolean value true if Dreamweaver can edit delete or dupli...

Page 580: ...Boolean value true if the contents can display false otherwise dreamweaver resultsPalette canCut Availability Dreamweaver MX Description Checks whether the current Results window can display a Cut mes...

Page 581: ...report can display in a browser Arguments None Returns A Boolean value true if the contents can display false otherwise dreamweaver resultsPalette canOpenInEditor Availability Dreamweaver MX Descripti...

Page 582: ...bility Dreamweaver MX Description Checks whether a Select All message can be sent to the window that is currently in focus Arguments None Returns A Boolean value true if the Select All message can be...

Page 583: ...None Returns A Boolean value true if the Change Action to Delete context menu can be displayed false otherwise dreamweaver siteSyncDialog canMarkGet Availability Dreamweaver 8 Description This functio...

Page 584: ...None Returns A Boolean value true if the Change Action to Ignore context menu can be displayed false otherwise dreamweaver siteSyncDialog canMarkPut Availability Dreamweaver 8 Description This functio...

Page 585: ...lette canEditSnippet Availability Dreamweaver MX Description Checks whether you can edit the currently selected item and returns either a true or false value so you can enable or disable menu items fo...

Page 586: ...ser command Arguments browserName The browserName argument is the name of a browser as defined in the Preview in Browser preferences If omitted this argument defaults to the user s primary browser Ret...

Page 587: ...Dreamweaver can perform a Check In operation Arguments siteOrURL The siteOrURL argument must be the site keyword which indicates that the function should act on the selection in the Site panel or the...

Page 588: ...has focus the file is part of a local site and is not already checked out or if the Site panel has focus one or more files or folders are selected and at least one of the selected files is not alread...

Page 589: ...er Dreamweaver can perform the Compare function on selected files Arguments None Returns A Boolean value true if two files one local file and one remote file two local files or two remote files are se...

Page 590: ...ther Dreamweaver can perform a Get operation Arguments siteOrURL The siteOrURL argument must be the site keyword which indicates that the function should act on the selection in the Site panel or the...

Page 591: ...yword local and the second argument is a URL a Boolean value that indicates whether the document belongs to a site If the first argument is the keyword remote and the second argument is a URL a Boolea...

Page 592: ...rform a New File or New Folder operation in the Site panel Arguments None Returns A Boolean value true if any files are visible in the selected pane of the Site panel false otherwise site canOpen Avai...

Page 593: ...ment is the keyword site returns the value true if any files or folders are selected in the Site panel and a remote site has been defined otherwise false If the argument is a URL returns the value tru...

Page 594: ...r remote keyword Returns A value of true if the localOrRemote argument is the local keyword otherwise a Boolean value that indicates whether a remote site has been defined site canRemoveLink Availabil...

Page 595: ...otherwise site canSelectAllCheckedOutFiles Availability Dreamweaver 4 Description Determines whether the current working site has the Check In Check Out feature enabled Arguments None Returns A Boole...

Page 596: ...canShowPageTitles Availability Dreamweaver 3 Description Determines whether Dreamweaver can perform a Show Page Titles operation Arguments None Returns A Boolean value true the site map is visible fal...

Page 597: ...specified folder and all its contents Returns A Boolean value true if Dreamweaver can perform the uncloaking operation on the current site or the specified folder false otherwise site canUndoCheckOut...

Page 598: ...ewAsRoot Availability Dreamweaver 3 Description Determines whether Dreamweaver can perform a View as Root operation Arguments None Returns A Boolean value true if the specified file is an HTML or Flas...

Page 599: ...yTemplate 385 arrange 443 arrangeFloatingPalettes 452 arranging floating panels 452 hotspots 443 arrowDown 173 527 arrowLeft 174 528 arrowRight 174 528 arrowUp 175 529 assetPalette addToFavoritesFromD...

Page 600: ...ClipCopy 564 canClipCopyText 552 canClipCut 565 canClipPaste 553 565 canClipPasteText 553 canCloak 588 canConnect 589 canConvertLayersToTable 554 canConvertTablesToLayers 554 canCopy 580 canCut 580 ca...

Page 601: ...cting JavaBeans 112 113 114 cleaning up XHTML documents 302 cleanupXHTML 302 clear 192 clearGuides 468 clearing History panel 166 clearServerScriptsFolder 30 clearSteps 165 clearTemp 31 Clipboard func...

Page 602: ...nnectivity overview 101 conventions in book 13 conversion functions 299 converting file URL to local drive path 43 50 from percentage to pixels 477 from pixels to percentage 477 local drive path to a...

Page 603: ...82 MMDB showColdFusionAdmin 83 MMDB showConnectionMgrDialog 83 MMDB showOdbcDialog 83 MMDB showRdsUserDialog 84 MMDB showRestrictDialog 84 MMDB showResultset 97 MMDB showSPResultset 98 MMDB showSPRes...

Page 604: ...300 Dynamic Data 158 Dynamic Text 158 Edit Command List 300 Edit Style Sheet 432 Export Editable Regions as XML 310 Export Styles as a CSS File 309 Find 499 Grid Settings 452 New CSS Style 428 New Doc...

Page 605: ...deFragment 243 collapseSelectedCodeFragmentInverse 243 convertLayersToTable 299 convertTablesToLayers 300 convertToXHTML 303 convertWidthsToPercent 477 convertWidthsToPixels 477 createHorizontalGuide...

Page 606: ...ToolbarLabel 225 getToolbarVisibility 225 getTracingImageOpacity 447 getView 230 getWindowTitle 230 guidesColor 471 guidesDistanceColor 471 guidesLocked 472 guidesSnapToElements 473 guidesVisible 473...

Page 607: ...Ds 462 setShowBoxModel 463 setShowDivBackgrounds 426 setShowDivBoxModel 426 setShowDivOutlines 427 setShowFrameBorders 207 setShowGrid 207 setShowHeadView 208 setShowHiddenCharacters 250 setShowImageM...

Page 608: ...pply 564 assetPalette copyToSite 357 assetPalette edit 357 assetPalette getSelectedCategory 358 assetPalette getSelectedItems 358 assetPalette getSelectedView 359 assetPalette insertOrApply 359 assetP...

Page 609: ...ing 344 editCommandList 300 editFontList 517 editLockedRegions 349 exportCSS 309 exportEditableRegionsAsXML 310 exportTemplateDataAsXML 310 findNext 494 fitAll 465 fitSelection 465 fitWidth 466 getAct...

Page 610: ...63 libraryPalette getSelectedItem 364 libraryPalette newFromDocument 364 libraryPalette recreateFromDocument 365 libraryPalette renameSelectedItem 365 liveDataTranslate 405 loadSitesFromPrefs 259 mapK...

Page 611: ...cDialog markGet 260 siteSyncDialog markIgnore 261 siteSyncDialog markPut 261 siteSyncDialog markSynced 262 siteSyncDialog toggleShowAllFiles 262 snippetPalette editSnippet 393 snippetPalette getCurren...

Page 612: ...removing from 362 features source control systems 127 128 file I O API about 17 DWfile copy 17 DWfile createFolder 18 DWfile exists 19 DWfile getAttributes 19 DWfile getCreationDate 21 DWfile getCrea...

Page 613: ...66 SWFFile readFile 66 Flash path to 150 floating panel functions 229 floating panels arranging 452 folders _mmServerScripts 30 checking in 129 checking in out source control systems 130 configuratio...

Page 614: ...egionList 386 getEditNoFramesContent 198 getElementRef 326 getErrorMessage 115 getEvents 112 getExtDataArray 400 getExtDataValue 400 getExtensionEditorList 149 getExternalTextEditor 149 getExtGroups 4...

Page 615: ...wBlockBorders 459 getShowBlockIDs 460 getShowBoxModel 461 getShowDependents 219 getShowDialogsOnInsert 156 getShowFrameBorders 200 getShowGrid 200 getShowHeadView 201 getShowHiddenCharacters 249 252 g...

Page 616: ...169 selecting 170 hotspot functions 443 hotspots arranging 443 moving 444 sizing 444 445 HTML cascading style sheets 299 connections 106 converting to XHTML 303 creating new documents 307 inserting 5...

Page 617: ...ct 508 insertSnippet 394 insertTableColumns 482 insertTableRows 482 insertText 508 inspectConnection 105 Internet Explorer rendering 420 invalid HTML 200 201 216 invertSelection 281 isCloaked 281 isCo...

Page 618: ...cal file path converting to site relative URI 257 local file path converting to site relative URI 257 local root folder 334 LocalURLToFilePath 50 locateInSite 282 locking guides 472 login information...

Page 619: ...85 MMHttp clearServerScriptsFolder 30 MMHttp clearTemp 31 MMHttp getFile 31 MMHttp getFileCallback 33 MMHttp getTextCallback 34 MMHttp postText 35 MMHttp postTextCallback 36 MMJB getClasses 111 MMJB...

Page 620: ...ackages JavaBeans classes 112 page content functions 355 Page Down 178 Page Up 179 pageDown 178 536 pageUp 179 536 parameter of stored procedures 95 passed in folders files in 122 passing JavaScript t...

Page 621: ...s 457 removeAllTableHeights 483 removeAllTableWidths 484 removeBehavior 370 removeCharacterMarkup 510 removeColumnWidth 484 removeComment 251 removeCSSStyle 424 removeEditableRegion 390 removeFontMark...

Page 622: ...ing check out 130 reverting documents 317 root folder names 121 row span decreasing 478 ruler origin 446 ruler units 446 runCommand 301 runtime connection types 78 runTranslator 349 runValidation 288...

Page 623: ...teWithErrorChecking 512 setBlockVisOutlineProperties 439 setButtons 188 setCallbackCommands 189 setCloakingEnabled 291 setColumnAutostretch 458 setColumnWidths 189 setConnectionState 291 setCurrentLin...

Page 624: ...3 showDynamicData 157 showFindDialog 499 showFindReplaceDialog 500 showFontColorDialog 516 showGridSettingsDialog 452 showInfoMessagePopup 324 showInsertTableRowsOrColumnsDialog 487 showListProperties...

Page 625: ...289 290 setAsHomePage 291 setCloakingEnabled 291 setConnectionState 291 setCurrentSite 292 setFocus 292 setLayout 293 setLinkVisibility 293 setSelection 294 setShowDependents 220 setShowHiddenFiles 22...

Page 626: ...g comment 141 check out name 129 connecting to 120 connections 126 creating folders 124 deleted sites 127 deleting files 124 Design Note keys 133 Design Notes 134 135 Design Notes length 134 disconnec...

Page 627: ...tag layers 445 tags font 501 inserting 160 template and library functions 384 testAppServer 418 testConnection 85 testing connection strings 85 text editing operation 163 getting 162 posting 36 text e...

Page 628: ...rmining 230 selecting 230 visible 235 view tables 96 viewAsRoot 297 views 96 visible 230 visible files 25 visual aids 199 205 438 439 Layout Block Backgrounds 422 426 layout Block Backgrounds 439 Layo...

Reviews: