共用方式為


responseText property

Contains the body of the response returned by the server.

 

Syntax

HRESULT value = object.get_responseText(BSTR* p);

Property values

Type: BSTR

the text received from the server.

Remarks

After the IHTMLXDomainRequest::onload event has been raised, IHTMLXDomainRequest::responseText contains the complete server response.

In the time after the IHTMLXDomainRequest::onprogress event is raised and before the IHTMLXDomainRequest::onload event is raised, IHTMLXDomainRequest::responseText contains either a partial response or the complete server response.

The IHTMLXDomainRequest::responseText value is an empty (zero-length) string in three cases:

  1. before the IHTMLXDomainRequest::onprogress event is raised
  2. after the IHTMLXDomainRequest::onprogress event is raised and before the first character has been received
  3. after the IHTMLXDomainRequest::onload event is raised and the server has returned an empty string as a response

Examples

For an example of how this property is used, see Introducing Cross-domain Request.

See also

Reference

IHTMLXDomainRequest

XDomainRequest