Adobe uses JavaScript files to implement much of Dreamweaver's functionality. This heavy use of JavaScript makes Dreamweaver easily extensible. Developers can change the native functionality of Dreamweaver. However, the errors that Dreamweaver generates if it encounters a problem executing an action tend to be JavaScript errors.
These design-time JavaScript errors, such as "While executing onLoad in tempURL_afterSave.htm, a JavaScript error occurred," usually prevent you from implementing a portion of Dreamweaver functionality.
Sometimes, a translator error message accompanies these internal JavaScript errors:
"The following translators were not loaded due to errors: ASP.htm: has configuration information that is invalid. ASP.NET.htm: has configuration information that is invalid. ColdFusion.htm: has configuration information that is invalid. PHP_MySQL.htm: has configuration information that is invalid. JSP.htm: has configuration information that is invalid. XSLT.htm: has configuration information that is invalid."
Note:
JavaScript errors that pop up in Dreamweaver are different from JavaScript runtime errors you encounter when viewing a page in a web browser. JavaScript errors in a web browser indicate a problem with embedded or linked JavaScript in the HTML page. These types of runtime JavaScript errors are beyond the scope of this article. See Dreamweaver help files or a third-party JavaScript reference for troubleshooting hand-coded JavaScript.
Common causes of JavaScript errors in Dreamweaver include a conflicting Dreamweaver extension, a conflict with code on a page, or a bad installation of Dreamweaver. These questions can help you isolate the issue:
- Does the error occur when you're using a specific feature?
For example, do you see the same error message every time you attempt to create a web photo album? This error may indicate a conflicting extension or a bad installation of Dreamweaver.
- Does the error occur on a specific page or with all pages?
If the error doesn't occur with all pages, then you may have a conflict with code on a particular page.
- Does the error occur in all sites or just one?
To test this issue properly, make sure that you test a different site that does not use the same files. If the error occurs only in a certain site, then the issue may be specific to files and code within that site.
- Does the problem persist if you restart Dreamweaver?
If the problem does not recur on relaunching Dreamweaver, then a JavaScript file may have initially loaded incorrectly.
- If you're using a server behavior, does the problem occur with all databases and tables?
If not, then you may have an issue with the database connection files or with the tables of the database itself.
After answering the questions above, try the troubleshooting techniques below to solve any issues you're having with JavaScript in Dreamweaver.
Updates provide fixes for a number of issues with Adobe applications. Download updates from the Dreamweaver updates page. Learn more at Update Creative Cloud apps.
For example, if you have a behavior applied to an image, then that image must have a name in the code. Likewise, if the behavior references another image, then that image must also have a name. All object names must be unique and must meet other criteria.
-
Locate the Dreamweaver user configuration folder:
- Mac OS: [user name]/Library/Application Support/Adobe/Dreamweaver [version]/[language]/Configuration
- Windows 7 or Windows Vista: C:/Users/[user name]/AppData/Roaming/Adobe/Dreamweaver [version]/[language]/Configuration
- Windows XP: C:/Documents and Settings/[user name]/Application Data/Adobe/Dreamweaver [version]/[language]/Configuration
Note:
The Application Data and AppData folders are hidden by default. For help, see Show hidden files and folders (Windows) or Access hidden files (Mac OS).
Conflicting code or Dreamweaver behaviors can be on a page. Try building a page from scratch with minimal behaviors and other design elements to see if you can reproduce the error. Custom code or modified Dreamweaver code can occasionally cause problems.
In particular, this procedure is useful for JavaScript errors related to templates, library items, and uploading files. This procedure is possible only if the site is defined to use a site cache:
- In Dreamweaver, open the Site panel by choosing Window > Files.
- From the Files panel group, click the Options menu in the upper-right corner, and choose Site > Recreate Site Cache.
If the JavaScript occurs in only one site definition, then delete the site cache file for that site. To delete the cache, choose Site > Advanced > Recreate Site Cache.
Check for any special characters in the hard drive name, in the path to the Dreamweaver configuration folder, or in the path to your site files. Examples of special characters that can cause conflicts include the following:
~ @ # $ % ^ & * ( ) + | / \ ' ;
An extension installed in Dreamweaver can be causing a conflict. For example, an extension could have been designed to work with an older version of Dreamweaver. Check the extension developer's website to see if the extension is compatible with your version of Dreamweaver.
Several JavaScript errors are associated with third-party extensions. Try searching the Dreamweaver Community for solutions. Search using some of the keywords in your JavaScript error message (for example, search using the text of the JS filename).
To manually test for an extension conflict, disable all the extensions you installed in Dreamweaver. If disabling extensions solves the problems, enable them one by one until you isolate the problematic extension. If you identify a problematic extension, notify the extension developer.
- Go to Adobe Add-ons page to view your add-ons.
- Click Remove to the right of the extension names to disable them.
- Choose Commands > Manage Extensions.
- In the Extension Manager, select your version of Dreamweaver from the product list
- In the list of installed extensions, set the On/Off option to Off for all Dreamweaver extensions.
If the JavaScript error persists after you disable all the extensions, then uninstall the extensions in the Extension Manager. If you identify a problematic extension, notify the extension's author.
- In the Extension Manager, select each extension.
- Choose File > Remove Extension.
- Quit Dreamweaver.
- Find the Dreamweaver configuration folder:
- The configuration folder is hidden on Mac OS X 10.7 and later. To reveal it, open the Finder and press Cmd+Shift+G.
- Type /Library/Application Support in the dialog box, and click Go.
- In the Application Support window, browse to /Adobe/Dreamweaver [version]/[language]/Configuration.
Note:
For earlier versions of Mac OS, in the Finder, browse to the following folder: /[user]/Library/Application Support/Adobe/Dreamweaver [CS4 or CS5]/[language]/Configuration
- Quit Dreamweaver.
- Find the Dreamweaver configuration folder:
- The configuration folder is hidden on Windows. To reveal hidden folders, see Show hidden files and folders.
- Locate the configuration folder at this path: C:/Users/[user name]/AppData/Roaming/Adobe/Dreamweaver [version]/[language]/Configuration
- Rename the folder Configuration Old.
- Restart Dreamweaver to see if the problem persists.
Restart your computer in safe mode and then launch Dreamweaver to see if issue persists:
- Windows 8, see Windows startup settings (including safe mode).
- Windows Vista/7, see Restart Windows in a modified mode (Windows Vista/7).
- Windows XP, see Start Windows in Diagnostic mode (Windows XP).
- Mac OS, see Start in Safe Boot mode | Mac OS X.
If the issue is cleared up when you start in safe mode, try restarting again without safe mode. If the issue is resolved when you start up normally, it was possibly caused by an issue that safe mode fixed.