WinHttp.winhttpRequest.5.1 is the underlying object of MSXML4.0, that is, XMLHTTP/Serverxmlhttp is also encapsulated on it. Winhttprequest usage is roughly the same as xmlhttp.
The following discussion is the use of WinHttp.winhttpRequest.5.1 related to WinHttpRequest.5.1 related ASP acquisition function and attributes. The content is the tutorial carefully selected and organized on this site. I hope to help the majority of netizens. Details:
Recently, I was trying to get a remote web server response header, and learned about Winhttp.winhttpRequest.5.1 component
Using WinHttpRequest can forge HTTP header information and fake information such as Referer. Because Microsoft has blocked the XMLHTTP object, it is impossible to fake some HTTP header information, but WinHttp.winhttpRequest.5.1 objects, it actually uses the Header information that can be successfully forged all HTTP requests!
It is learned from msdn that WinHttp.winhttpRequest.5.1 is the underlying object of MSXML4.0, which means that XMLHTTP/Serverxmlhttp is also encapsulated on it. The usage of WinhttpRequest is roughly the same as xmlhttp.
When WaitForResponse sends a request in an asynchronous manner, you can use this method to control the process of request. The specified waiting time, the value completed by second as an asynchronous transmission method, settimeouts.
In the server script, you must not directly use the callback function to control asynchronous requests like a client, and there is no corresponding function to use the program to sleep for a certain time. Therefore, in order to wait for the request to return, we can use this method to wait for a certain period of time to take a certain time for a certain time. Essence
The code is as follows:
The program code (for alixixi.com) is as follows: