From: joey on
I met exactly the same problem. what's the solution then?

"adrianl" wrote:

> Hello,
> I'm experiencing a problem running the following Javascript code when the
> URL is pointing to an IIS 7.0 server:
> var url = "http://iis7srv/TestWeb/test.txt";
> var x = new ActiveXObject("Msxml2.XMLHTTP.6.0");
>"PUT", url, false, "", "");
> x.setRequestHeader( "Content-Type", "text/plain" );
> var b = "Testing!";
> x.send(b);
> What I've found is that if I run this and the test.txt file doesn't
> currently exist, then the code succeeds; IIS returns a "201" status code and
> creates the test.txt file. But when I run it when the file does exist, the
> PUT appears to succeed (the last modified timestamp of test.txt updates, and
> IIS returns "204"), but "send" throws an exception ("Operation aborted.").
> Note that this problem does not happen when the URL is pointing to an IIS
> 6.0 machine.
> I have a feeling I have missed something very obvious. I've searched for
> others having this problem and found nothing. Can anyone offer any advice?