- Joined
- Jun 25, 2005
- Messages
- 2
- Reaction score
- 0
Is it possible to save a variable from HTML's javascript or vbscript into XML files? Or is it a must to use ASP or PHP? T. T
The following code is what I have typed, and it doesn't work
unless i typed the /*xmlDoc.Save "c:\test.xml"*/ then the document.write(xmlDoc.documentElement.childNodes.item(0).text) works but all i want is the xmlDoc.documentElement.childNodes.item(0).text="1" part to work T_T can someone teach me? 
Btw: I used VBscript
The following code is what I have typed, and it doesn't work
Btw: I used VBscript
Code:
[B]Html Code(dd.html)[/B]
<script type="text/vbscript">
dim xmlDoc
Set xmlDoc = server.CreateObject("Microsoft.XMLDOM")
xmlDoc.async="false"
xmlDoc.load("xml_note.xml")
document.write(xmlDoc.documentElement.childNodes.item(0).text)
xmlDoc.documentElement.childNodes.item(0).text="1"
xmlDoc.Save "c:\test.xml"
</script>
Code:
[B]XML Code(xml_note.xml)[/B]
<?xml version="1.0" encoding="ISO-8859-1"?>
<catalog>
<ddd>Test</ddd>
</catalog>

