XMLDOM object method: Object event

Source: Internet
Author: User

Ondataavailable event

For use

This event is triggered when the XML file is valid.

Basic syntax

This event can be handled in the following three ways:
. Inline: <element ondataavailable = handler>;
. Event property: object. ondataavailable = handler;
. Named script: <script for = object EVENT = ondataavailable>;
 

Description

An ondataavailable event is triggered when valid data is obtained. This technology does not indicate how much data is valid in this file.

Example

XmlDoc. ondataavailable = alert ('data is now available .');

Onreadystatechange event

For use

This event is triggered when the content of the readyState attribute changes.

Basic syntax

This event can be handled in the following three ways:
. Inline: <element onreadystatechange = handler>;
. Event property: object. onreadystatechange = handler;
. Named script: <script for = object EVENT = onreadystatechange>;
 

Description

The onreadystatechange event is triggered when the content of the readyState attribute changes, but this event does not indicate the status of the "prepared" event. You must use the readyState attribute to obtain the current state.

Example

XmlDoc. onreadystatechange =
Alert ("The readyState property is" + xmlDoc. readyState );

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.