readyState
statusText
onreadystatechange
window.status
What's the difference between 'state' and 'status' in English ?
Not much. I would tend to say state refers to more detailed information, but that's subjective.
For these:
XMLHttpRequest.readyState - one of 5 possible states for a request
XMLHttpRequest.statusText - The text equivalent of the HTTP response status (e.g. "200 OK")
XMLHttpRequest.onreadystatechange - function to call when readyState changes
window.status - status bar text (typically bottom left of window)
They are quite similar, as they both signify the current properties of something. There is however a bit of a difference in how they are used:
A state is usually a single propery with some specific possible values. The readyState
for example will cycle through some specific predefined values when a page loads.
The status is usually a collection of properties, or a description of them. The window.status
property for example is just the text that is displayed in the status bar, and that can descibe any aspect of the content.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With