• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 524
  • Last Modified:

permition

When I tryed to save the data to the xml file:
{
xmlDom.save('Customer.xml')
}
, it gives the error message  "Access is denied" (one word permission)

How can I give permission to write data to the xml file?
0
dik_sychev
Asked:
dik_sychev
  • 2
  • 2
  • 2
  • +3
1 Solution
 
lexxwernCommented:
is it a unix server, if so then chmod it and give it 777 rights.
0
 
DreamMasterCommented:
And if it is a windows server, right click on the file, choose properties, then security and change the security settings to suite your needs..

Max.
0
 
CJ_SCommented:
And if it is on the client you cannot due to security constraints.

CJ
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
CJ_SCommented:
Make it an .hta file if you do want it to save.

CJ
0
 
lexxwernCommented:
or maybe use the .htaccess file to define rights in your directory,

more help at http://www.apache.org/
0
 
zvonkoCommented:
You have to set "Accessing Data Across Domains" to "enable"
Local files are treated as own domain.
Look here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsdk30/htm/xmconxmlclientsecurity.asp
0
 
zvonkoCommented:
Hello,

try this:
<html>
<script language="JavaScript">
function writeXML()
{
var oXML = new ActiveXObject("Microsoft.XMLDOM");
var oRoot = oXML.createNode("element", "customers", "");
oXML.appendChild(oRoot);
var oNode = oXML.createNode("element", "customer","");
oRoot.appendChild(oNode)
var oNode2 = oXML.createNode("element", "order","");
oNode.appendChild(oNode2)
alert(oXML.xml)
   var fso = new ActiveXObject("Scripting.FileSystemObject");
   var MyFile = fso.CreateTextFile("c:\\prices.xml", true);
   MyFile.Write(oXML.xml);
   MyFile.Close();
}
writeXML();
</script>
</html>

Good luck,
zvonko

0
 
ahosangCommented:
This question has been abandoned. I will make a recommendation to the moderators on its resolution in a week or so. I appreciate any comments that would help me to make a recommendation.
 
In the absence of responses, I may recommend DELETE unless it is clear to me that it has value as a PAQ. Silence = you don't care
 
ahosang
0
 
ahosangCommented:
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

PAQ
Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
ahosang
EE Cleanup Volunteer
0
 
SpideyModCommented:
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
  • 2
  • 2
  • +3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now