Creating Documents  «Prev  Next»

XML Programming Quiz

Each question is worth one point. Select the best answer or answers for each question.
 
1. What must you do when creating your own well-formed XML document from existing text?
Please select the best answer.
  A. Use the recognized set of XML tags.
  B. Define a set of tags that will best accomplish your purpose.
  C. Use the set number of tags specified by the W3C.
  D. Use CDATA sections
  E. Use predefined tags available to XML users.

2. Which two of the following methods are used to add information to XML documents?
Please select all the correct answers.
  A. Using CDATA sections to include special characters
  B. Including the encoding information used to create the XML document
  C. Using comment tags to embed script
  D. Using CDATA sections to specify the character set used in the XML document

3. John has created the following XML document to track client addresses but the document will not load in a browser.
 
<?xml version="1.0"?> 
<NAME> John Smith </NAME> 
<ADDRESS>
 <street>198 Harrison</STREET> 
 <CITY>San Francisco</CITY> 
 <STATE> CA </STATE> 
 <ZIP> 56110 </ZIP>
        

What well-formedness rules does the document violate?
Please select all the correct answers.
  A. The document has no root element.
  B. The tags do not nest in order.
  C. There is no closing </ADDRESS> tag.
  D. D. The <STREET> tags do not match in case.