- From: Lori Hylan-Cho <lorihc@adobe.com>
- Date: Mon, 9 Jul 2007 10:08:03 -0700
- To: <www-validator@w3.org>
hello I am experimenting with the validator's web service API, and I've noticed that while I can get a SOAP 1.2 reply for HTML fragments, if I validate by URI I always get an HTML reply. I'm doing an HTTP post from JavaScript. The function I'm using takes two arguments: the URL of the server, and the text to post. For example: var docContents = document.documentElement.outerHTML; /* gets entire document source, including !DOCTYPE statement */ var result = httpPostText("http://validator.w3.org/check", "fragment=" + encodeURIComponent(docContents) +"&output=soap12"); In the above case, I get a SOAP reply. However, if I substitute a URL instead of raw HTML, as shown below... var docContents = "http://www.avocado8.com/index.shtml"; var result = httpPostText("http://validator.w3.org/check", "uri=" + encodeURIComponent(docContents) +"&output=soap12"); I always get an HTML reply. I've tried encoding the & in front of the output argument, but the results are the same. Is there something else I should be doing? Have I misunderstood something major? Thanks in advance for any assistance. best, Lori
Received on Monday, 9 July 2007 20:31:46 UTC