JavaScript errors in Dreamweaver
Troubleshoot common issues with JavaScript in Dreamweaver.

Understand JavaScript errors

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.

Causes of JavaScript errors

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.

Troubleshooting techniques

After answering the questions above, try the troubleshooting techniques below to solve any issues you're having with JavaScript in Dreamweaver.

Install the latest Dreamweaver updates.

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.

Verify that any object referenced by the JavaScript is named in the code.

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.

Delete FileCache.dat files from the Dreamweaver user configuration folder.

  1. 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).

  2. Delete these files:

    • Windows: WinFileCache-7A9586CB.dat
    • Mac OS: MacFileCache-BFE7CE2E.dat

    The string of characters after "FileCache-" can differ depending on your system.

  3. If you're experiencing a JavaScript error related to "dwscripts" or if you receive a "translators were not loaded" error, also delete this file:

    • FileCache.dat file

    The location of the FileCache.dat file depends on your operating system and your version of Dreamweaver.

Build a new page.

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.

Re-create the site cache and see if the problem persists.

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:

  1. In Dreamweaver, open the Site panel by choosing Window > Files.
  2. From the Files panel group, click the Options menu in the upper-right corner, and choose Site > Recreate Site Cache.

For site-specific errors, try deleting the .dws site cache file.

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.

Mac OS users: Change special characters in paths.

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:

~ @ # $ % ^ & * ( ) + | / \ ' ;

Verify that extensions are compatible with your version of Dreamweaver.

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).

Disable extensions.

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.

Dreamweaver (2015 and later):

  1. Go to Adobe Add-ons page to view your add-ons.
  2. Click Remove to the right of the extension names to disable them.

Dreamweaver (2014 and earlier):

  1. Choose Commands > Manage Extensions.
  2. In the Extension Manager, select your version of Dreamweaver from the product list
  3. In the list of installed extensions, set the On/Off option to Off for all Dreamweaver extensions.

Uninstall 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.

  1. In the Extension Manager, select each extension.
  2. Choose File > Remove Extension.

Recreate the Dreamweaver user configuration folder.

Mac OS

  1. Quit Dreamweaver.
  2. 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

3.   Rename the folder Configuration Old.

4.   Restart Dreamweaver to see if the problem persists.

Windows 8, 7, Vista

  1. Quit Dreamweaver.
  2. 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
  3. Rename the folder Configuration Old.
  4. Restart Dreamweaver to see if the problem persists.

Run Dreamweaver in selective startup or safe mode.

Restart your computer in safe mode and then launch Dreamweaver to see if issue persists:

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.

Additional help

If the JavaScript errors persist after you follow the suggestions above, then see the following help document for additional troubleshooting suggestions. Uninstalling and reinstalling Dreamweaver, with anti-virus software disabled, is an important test to perform: