What does AJAX stand for?
A
Advanced Java Application for XML
B
Asynchronous JavaScript and XML
C
Automated JSON Access and XML
Analysis & Theory
AJAX stands for **Asynchronous JavaScript and XML**, used to fetch data from a server without refreshing the page.
What is the primary advantage of using AJAX?
A
It makes web pages heavier
B
It reloads the entire page after every request
C
It allows web pages to update asynchronously without reloading
D
It forces users to use XML only
Analysis & Theory
**AJAX allows** data to be fetched and displayed **without reloading** the entire webpage.
Which JavaScript object is used to send AJAX requests?
Analysis & Theory
`XMLHttpRequest` is the **built-in JavaScript object** used for AJAX communication.
Which technologies are commonly used with AJAX?
A
HTML, CSS, JavaScript, and XML/JSON
Analysis & Theory
**AJAX is a combination** of technologies like **HTML, CSS, JavaScript, XML/JSON, and DOM**.
Which of the following is TRUE about AJAX?
A
AJAX can only send GET requests
B
AJAX requires a browser plugin
C
AJAX improves user experience by avoiding page reloads
D
AJAX can only work with XML
Analysis & Theory
**AJAX improves UX** by enabling partial updates without reloading the whole page.
What happens when an AJAX call is made?
B
A background HTTP request is sent to the server
C
The server stops responding
D
The browser gets locked
Analysis & Theory
**AJAX sends asynchronous HTTP requests** to the server in the background.
Which HTTP methods are commonly used in AJAX?
Analysis & Theory
`GET` is used to retrieve data, and `POST` is used to submit data in AJAX operations.
What does `xhr.open('GET', url, true)` do in AJAX?
A
It executes the request immediately
B
It creates and sends a new HTML page
C
It prepares a new asynchronous GET request to a URL
Analysis & Theory
`xhr.open()` prepares an **asynchronous request** using the specified method and URL.
Which property holds the response text in AJAX?
Analysis & Theory
`xhr.responseText` contains the **raw text** of the server's response.
Which event is triggered when an AJAX response is received?
Analysis & Theory
`onload` is triggered when the **AJAX response is fully received** and ready to use.