JavaScript Technology Extensions Flashcards
The readyState value in an AJAX transaction can be between 0 and 4. This value determines the state of the XMLHttpRequest object at the time that the script asks for the state.
True
Readystate value
The readyState value in an AJAX transaction can be between 0 and 4. This value determines the state of the XMLHttpRequest object at the time that the script asks for the state.
Monitoring these states helps to ensure that the data remains secure.
The XMLHttpRequest object does not perform the transfer of data between a client and a server, it is done by HTTP or HTTPS. It requests the transfer of any XML or text-based data between a client and server. .
The readyState property is used to determine the state of the XMLHttpRequest object, which helps in keeping a track of operations that have been performed, and the operations that are still pending
A schema is a description of the tables and fields in a database, the relationships among them, and the structure to organize and describe the data.
True
AJAX is most known for its asynchronous calls that allow developers to update a section of the webpage without loading the entire page again.
True
AJAX can handle a variety of server requests for end-users. A typical AJAX-based request is returning server variables from the server to the client. This can be used to update content such as date and time.
True
Which method initializes an HTTP request?
The open() method initializes an HTTP request. It must be invoked before the request is sent.
Which programming language is typically used in AJAX transactions to query databases?
SQL
What is the main role of JavaScript in an AJAX transaction?
The main role of JavaScript in an AJAX transaction is to manipulate the DOM (Document Object Model), changing the elements in the browser. XML is used to control the browser display in the context of the content. The XMLHttpRequest object is used to request data and send responses, from and to a server, respectively.
Readystate table
readyState
State
Description
0
Uninitialized
An XMLHttpRequest object has been created, but not initialized.
1
Ready
Code has called the XMLHttpRequest open() method, and the XMLHttpRequest object is ready to send a request to the server.
2
Sent
A request has been sent from the client to the server with the send() method, but a response has not yet been received.
3
Receiving
The HTTP response headers have been received from the server, but the message body has not yet been completely received from the client.
4
Loaded
The response has been completely received by the client.
How do XML and JSON differ?
XML requires an XML parser, whereas JSON can be directly parsed through the JavaScript parser. Both XML and JSON are hierarchical, can be fetched using the XMLHttpRequest object, and can send and receive data as text.
What does the XMLHttpREquest requests?
The XMLHttpRequest object requests the transfer of XML or JSON data between a client and a server. The data transfer is performed by HTTP or HTTPS.
What does the readyState value 1 say about the state of the XMLHttpRequest object?
A readyState value of 1 signifies that the XMLHttpRequest object is in the ready state. It means that the open() method has been called and the XMLHttpRequest object is ready to send a request to the server
What relationship describes an association between two tables in which one record of either table is related to the many records of another table?
A many-to-many relationship refers to a relationship between tables in a database when a parent row in one table contains several child rows in the second table, and vice versa. For example, a many-to-many relationship exists between customers and products. In this relationship, customers can purchase various products, and products can be purchased by many customers.
What is the format of the data that is exchanged with the browser using JSON?
Text