Skip to main content
Participant
May 9, 2007
Question

Writing to Configuration Folder

  • May 9, 2007
  • 2 replies
  • 366 views
I use the DWfile.write function to create files in various locations on my hard drive. I want to use the function to create a settings file that will be stored in the Dreamweaver Configuration folder that contains the extensions I am using. This will let the user change default values for the extensions, etc. Whenever I specify the Dreamweaver configuration folder as the desination in which to write the file, the function refuses to write the file. It doesn't return an error, but the file isn't created. The function works fine with the following parameters:

DWfile.write("file:///C|/Program Files/Macromedia/Dreamweaver MX 2004/" + "testfile.xml", str)

But when the destination directory is /Configuration or any directory inside /Configuration, the function doesn't work. For example, the following doesn't work (and yes, the folder name is correct):

DWfile.write("file:///C|/Program Files/Macromedia/Dreamweaver MX 2004/Configuration/" + "testfile.xml", str)

It seems that Macromedia has disabled writing to the Configuration folder for security reasons. Can anyone confirm this or suggest a way around the problem?
This topic has been closed for replies.

2 replies

Inspiring
May 9, 2007
Normally the way you would do this is to have the file alreayd created and stored in the configuration folder. Then, when the user applies the extension, the file is copied to their root directory, normally in an includes/extensionName folder.

Also, make sure you are veiwing/writing to the correct Configuration folder. There is a configuration folder that is hidden. Try going to C:/Documents and Settings/User Folder/Application Data/Macromedia/Dreamweaver 8/Configuration.
Inspiring
May 9, 2007
This TechNote explains how the DW Configuration folder is now handled on
multiuser systems:

http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_16420

HTH,
Randy



> I use the DWfile.write function to create files in various locations on my hard
> drive. I want to use the function to create a settings file that will be stored
> in the Dreamweaver Configuration folder that contains the extensions I am
> using. This will let the user change default values for the extensions, etc.
> Whenever I specify the Dreamweaver configuration folder as the desination in
> which to write the file, the function refuses to write the file. It doesn't
> return an error, but the file isn't created. The function works fine with the
> following parameters:
>
> DWfile.write("file:///C|/Program Files/Macromedia/Dreamweaver MX 2004/" +
> "testfile.xml", str)
>
> But when the destination directory is /Configuration or any directory inside
> /Configuration, the function doesn't work. For example, the following doesn't
> work (and yes, the folder name is correct):
>
> DWfile.write("file:///C|/Program Files/Macromedia/Dreamweaver MX
> 2004/Configuration/" + "testfile.xml", str)
>
> It seems that Macromedia has disabled writing to the Configuration folder for
> security reasons. Can anyone confirm this or suggest a way around the problem?
>