Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Parseing XML in ASP Page

From: Gadrin@-----.---
To: NULL
Date: 11/1/2005 9:40:00 PM
it looks like you're using VBScript inside the ASP.

as to the whether it's correct, can't help you unless I could look at
some examples (do they provide any? post a link if they do).

for instance Google's search API utilizes XML, and they provide
examples of the code.

I believe you send the document, so you would load the XML string into
a MS XML document, then send that document.
it returns text which I load into MS XML and save as XML file.

(this is a language similar to VBScript)

#include "C:\z\Inc\XMLTools.wbt"

;	here's a quick "for instance", you can send XML files to Google's
Search
;	API to get back data...

xfile = "J:\Temp Folders\GoogleTemp\googleapi\soap-samples\Copy of
doGoogleSearch.xml"
;xfile = "J:\Temp
Folders\GoogleTemp\googleapi\soap-samples\GoogleSearch No XML
Declaration.xml"

xmldoc = objectcreate("Msxml2.DOMDocument.4.0")
xmldoc.async = @false
xmldoc.load(xfile)

xmlhttp = objectcreate("Msxml2.XMLHTTP.4.0")
xmlhttp.Open("POST", "http://api.google.com/search/beta2", @false)
xmlhttp.Send(xmldoc)

message("Debug", xmlhttp.responseText)

GoogleResponseDoc = objectcreate("Msxml2.DOMDocument.4.0")
GoogleResponseDoc.async = @false
GoogleResponseDoc.loadXML(ParseXML(xmlhttp.responseText))

rfile = "J:\Temp Folders\GoogleTemp\googleapi\soap-samples\Winbatch
Test 2 Response.xml"
GoogleResponseDoc.save(rfile)

exit



transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent