Name: 
 

Practice Test on AJAX



True/False
Indicate whether the statement is true or false.
 

 1. 

AJAX primarily relies on JavaScript and HTTP requests to exchange data between a client computer and a Web server.
 

 2. 

AJAX cannot exchange data using standard text strings.
 

 3. 

You can use the XMLHttpRequest object to directly access content on another domain’s server.
 

 4. 

The ability for one Web server to access Web pages and data on another Web server is the foundation of the World Wide Web.
 

 5. 

The response returned from a server can be much more involved than the original request that generated it.
 

Multiple Choice
Identify the choice that best completes the statement or answers the question.
 

 6. 

AJAX gets its name from the fact that ____ is often the format used for exchanging data between a client computer and a Web server.
a.
ActiveX
c.
XML
b.
DOM
d.
HTTPS
 

 7. 

The XMLHttpRequest object uses ____ to exchange data between a client computer and a Web server.
a.
HTTP
c.
HTTPS
b.
FTP
d.
SSL
 

 8. 

By combining the ____ object with DHTML techniques, you can update and modify individual portions of your Web page with data received from a Web server.
a.
AjaxRequest
c.
HttpRequest
b.
XMLHttpRequest
d.
XMLRequest
 

 9. 

____ is an XML format that allows Web sites to publish content that can be read by other Web sites.
a.
AJAX
c.
PHP
b.
CSS
d.
RSS
 

 10. 

You can use a server-side script as a ____ to access data from another domain.
a.
proxy
c.
router
b.
switch
d.
firewall
 

 11. 

The purpose of the ____ policy is to prevent malicious scripts from modifying the content of other windows and frames and prevent the theft of private browser information and information displayed on secure Web pages.
a.
privacy
c.
delegation
b.
proxy
d.
same origin
 

 12. 

A(n) ____ is a software component that resides on a Web server.
a.
AJAX request
c.
HTTP service
b.
Web service
d.
DHTML service
 

 13. 

Every Web page is identified by a unique address called the ____.
a.
host string
c.
URL
b.
host
d.
HTTP
 

 14. 

The term ____ refers to the application, usually a Web browser, which makes the request.
a.
HTTP server
c.
HTTP URL
b.
host
d.
HTTP client
 

 15. 

The term ____ is another name for a Web server and refers to a computer that receives HTTP requests and returns responses to HTTP clients.
a.
URL
c.
HTTP server
b.
HTTP client
d.
host
 

 16. 

The term ____ refers to a computer system that is being accessed by a remote computer.
a.
protocol
c.
client
b.
host
d.
URL
 

 17. 

HTTP client requests and server responses are both known as HTTP ____.
a.
messages
c.
strings
b.
scripts
d.
queries
 

 18. 

____ define information about the request or response message and about the contents of the message body.
a.
Queries
c.
Headers
b.
Tags
d.
Labels
 

 19. 

____ refers to the temporary storage of data for faster access.
a.
Caching
c.
Shadowing
b.
Salting
d.
Hashing
 

 20. 

One generic header that requires special mention for AJAX applications is the ____ header, which specifies how a Web browser should cache any server content it receives.
a.
Caching
c.
CacheLevel
b.
Cache-Control
d.
Cached
 

 21. 

____ is a technology that allows programming objects to be easily reused with any programming language that supports Microsoft’s Component Object Model.
a.
AJAX
c.
DOCs
b.
DHTML
d.
ActiveX
 

 22. 

The ____ is an architecture for cross-platform development of client/server applications.
a.
Component Object Model
c.
RSS
b.
Dynamic HTML
d.
HTTPS
 

 23. 

After you instantiate an XMLHttpRequest object, you use the ____ method with the instantiated XMLHttpRequest object to specify the request method (such as GET or POST) and URL.
a.
alive()
c.
instantiate()
b.
create()
d.
open()
 

 24. 

To improve performance, you should call the ____ method of the XMLHttpRequest object to cancel any existing HTTP requests before beginning a new one.
a.
exit()
c.
cancel()
b.
abort()
d.
delete()
 

 25. 

After you have defined the basic request criteria with the open() method, you use the ____ method with the instantiated XMLHttpRequest object to submit the request to the server.
a.
pass()
c.
send()
b.
request()
d.
call()
 

 26. 

A(n) ____ request stops the processing of the JavaScript code until a response is returned from the server.
a.
asynchronous
c.
domain
b.
global
d.
synchronous
 

Completion
Complete each statement.
 

 27. 

____________________ (AJAX) refers to a combination of technologies that allow Web pages displayed on a client computer to quickly interact and exchange data with a Web server without reloading the entire Web page.
 

 

 28. 

Unlike standard HTTP requests, which usually replace the entire page in a Web browser, the ____________________ object can be used to request and receive data without reloading a Web page.
 

 

 29. 

The process of asking for a Web page from a Web server is known as a(n) ____________________.
 

 

 30. 

The Web server’s reply (which might consist of the requested Web page or a message about that Web page) is known as the ____________________.
 

 

 31. 

____________________ is a set of rules that defines how requests are made by an HTTP client to an HTTP server, and how responses are returned from an HTTP server to an HTTP client.
 

 

Matching
 
 
Match each item with a statement below:
a.
ECMAScript Edition 3
f.
Web services
b.
DHTML
g.
JavaScript programs
c.
XMLHttpRequest object
h.
Apache HTTP Server
d.
same origin policy
i.
Microsoft Internet Information Services
e.
proxy
 

 32. 

Restricts how JavaScript code in one window or frame accesses a Web page in another window or frame on a client computer
 

 33. 

The most popular Web server software used on the Internet
 

 34. 

Makes Web pages dynamic by combining JavaScript, XHTML, CSS, and the Document Object Model
 

 35. 

Provide services and data in the form of methods and properties
 

 36. 

The most recent version of the JavaScript language
 

 37. 

The second most popular Web server
 

 38. 

The key component of AJAX
 

 39. 

Someone or something that acts or performs a request for another thing or person
 

 40. 

Client-side scripting programs
 

Short Answer
 

 41. 

Briefly describe Google Suggest.
 

 42. 

How does the same origin policy affect AJAX?
 

 43. 

Why should you run AJAX from a Web server?
 

 44. 

What are the steps to create an AJAX script?
 

 45. 

Briefly describe the main characteristics of a Web page URL.
 

 46. 

Briefly describe TCP/IP.
 

 47. 

Describe the HTTP GET method.
 

 48. 

What is the format of the three-digit status codes returned from an HTTP server?
 

 49. 

What are the rules that your code should test for when instantiating an XMLHttpRequest object?
 

 50. 

How can you create an asynchronous request with JavaScript?
 



 
Check Your Work     Start Over