What’s the property to get the return value from Server in JavaScript?
-
xmlHttp.responseBody
-
xmlHttp.readyState.
-
xmlHttp.statusText.
-
xmlHttp.responseText.
D
Correct answer
Explanation
The responseText property contains the response body from the server as a string. The responseBody property (option A) is not a standard JavaScript XMLHttpRequest property. readyState (option B) indicates the request state (0-4). statusText (option C) contains the status message (e.g., 'OK').