Hi guys,
I am reposting because my topic/problem has become more refined.
I am passing an xml object to an asp page in this case using xml.sendAndLoad. as a test I want to capture the post data and write it to a text file. I have full permissions to do so and the file gets created…but with 0 bytes. No data.
Here is my flash code:
_root.searchXML = new XML();
searchlist = _root.searchXML.createElement(“searchlist”);
for(i=1;i<20;i++){
searchparam = _root.searchXML.createElement("searchparam");
param = _root.searchXML.createElement("param");
param.appendChild(_root.searchXML.createTextNode("param"+i));
paramvalue = _root.searchXML.createElement("paramvalue");
paramvalue.appendChild(_root.searchXML.createTextNode(_root["paramvalue"+i]));
searchparam.appendChild(param);
searchparam.appendChild(paramvalue);
searchlist.appendChild(searchparam);
}
_root.searchXML.appendChild(searchlist);
_root.searchXML.contentType = “text/xml”;
_root.menuXml_cars2 = new XML();
_root.menuXml_cars2.ignoreWhite = true;
_root.menuXml_cars2.onLoad = function(success) {
if(success){
//trace(“success!”);
}
}
trace(_root.searchXML);
_root.searchXML.sendAndLoad(“catalog/search.asp”, _root.menuXml_cars2);
**And here is my asp code:
<%
Dim strXML, fso, f
Const ForReading = 1, ForWriting = 2, ForAppending = 8
Set fso = CreateObject(“Scripting.FileSystemObject”)
Set f = fso.OpenTextFile(“C: estfile.txt”, ForWriting, True)
strXML = Request.Form
f.Write strXML
%>
**
this should work…when I do the trace call from within flash the xml object is definitely holding a tree…but for some reason it is not being passed or I cannot access it properly
Please…if anybody can point out a problem I do not see or knows of issues related to xml.sendAndLoad…
thx