Name: 
 

Study Guide 06



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

 1. 

You can use CSS to display a date that is entered in the XML document as “June 28, 2004” as “6/28/04.”
 

 2. 

With CSS, an element can be formatted multiple ways in a document.
 

 3. 

An XSLT style sheet is not in itself an XML document.
 

 4. 

The transformation of a source document to a result document can be performed by a server, but not by a client.
 

 5. 

In a client-side transformation, the client performs the transformation and generates its own result document.
 

 6. 

Apache’s client-side XSLT processor is called Saxon.
 

 7. 

All browsers have built-in support for XSLT.
 

 8. 

IE 5.0 and 5.5 are 100% compatible with the official XSLT standard.
 

 9. 

Creating a separate result document allows browsers without XSLT processors to view the results.
 

 10. 

XSLT style sheets do not have to follow the general structure of XML documents.
 

 11. 

Any XSLT-specific elements must be associated with the XSLT namespace.
 

 12. 

The XML declaration in the first line of any XML document is counted as part of the node tree.
 

 13. 

The root node is the same thing as the root element of the XML document.
 

 14. 

Above the root node is the processing instruction that links the .xml file with the XSLT style sheet and the root element.
 

 15. 

The relationship between the nodes in the node tree follows a familial structure.
 

 16. 

Nodes are distinguished based on the object they refer to in the document.
 

 17. 

XPath provides the syntax to refer to the various nodes in the node tree.
 

 18. 

The location of a node must be expressed in absolute (i.e., not relative) terms.
 

 19. 

By accessing the text nodes, you can use XSLT to create result documents that act upon the actual text content of the elements in the source document.
 

 20. 

The root template can be located anywhere between the opening and closing <xsl:stylesheet> tags of the XSLT document.
 

 21. 

Any tag that contains the “xsl” namespace prefix is treated by the XSLT processor as text, and is passed to the result document without modification.
 

 22. 

HTML tags do not have follow XML syntax.
 

 23. 

Simply creating a template does not cause the processor to use it in the result document; you must also indicate where you want the template applied.
 

 24. 

It is not necessary to include the select attribute with the <xsl:apply-templates> element.
 

 25. 

If you have a template matching an element located deep in the node tree, the default template continues processing until that template is applied.
 

 26. 

When there are multiple nodes involved in comparisons of node sets and single values, the expression is true when all of the nodes satisfy the test condition.
 

 27. 

Like other programming languages, XSLT supports an else-if construction.
 

 28. 

A predicate can indicate the position of a node in the node tree.
 

 29. 

To process a node from a specific location in the node’s tree branch, use the expression
node[position()=value]
where value is an integer indicating the node’s location in the branch.
 

Modified True/False
Indicate whether the sentence or statement is true or false.  If false, change the identified word or phrase to make the sentence or statement true.
 

 30. 

CSS displays only element attributes. _________________________

 
 
studyguide06_files/i0330000.jpg
 

 31. 

The item represented by the circle in the center of the figure above is the XSLT transformer. _________________________

 

 32. 

In a client-side transformation, the client does not need an XSLT processor because all of the work is done on the server. _________________________

 

 33. 

The open source XSLT processor developed by James Clark is called Xalan. _________________________

 

 34. 

A disadvantage to client-side transformations is the heavy load they can place on the server as it attempts to handle all the transformation requests. _________________________

 

 35. 

Netscape 6.0 fully supports the official W3C XSLT specifications. _________________________

 
 
studyguide06_files/i0390000.jpg
 

 36. 

The item indicated in the figure above is the XSLT namespace. _________________________

 

 37. 

It is common practice to put the root template at the bottom of the document, directly after the opening <xsl:stylesheet> tag. _________________________

 

 38. 

The version attribute of the <xsl:output /> element specifies the version of the output. _________________________

 

 39. 

The character attribute of the <xsl:output /> element specifies the character encoding. _________________________

 

 40. 

The omit-xml-declaration attribute of the <xsl:output /> element specifies whether to omit an xml declaration in the first line of the result document or to include it. _________________________

 

 41. 

The standalone attribute of the <xsl:output /> element specifies whether a standalone attribute should be included in the output and sets its value. _________________________

 

 42. 

One of the advantages of using templates instead of the <xsl:for-each> element is that you can break up the nodes of the source document into manageable chunks. _________________________

 

 43. 

A template can be called from other templates in the style sheet, making it very easy to reuse the same code in different locations in the source document. _________________________

 

 44. 

Each node type has its own built-in template. _________________________

 

 45. 

You can use the select attribute for templates that don’t yet exist. _________________________

 

 46. 

When you sort with the <xsl:apply-templates> element, the <xsl:apply-templates> element changes from an empty element into a two-sided element. _________________________

 

 47. 

When using the <xsl:sort> element with numeric value, if you try to sort the numbers 1 through 100, you’ll end up with the sort order 1, 10, 100, 11, 12, and so forth, because the default is to treat the element content as text. _________________________

 

 48. 

To select a subset of nodes from the node tree, use the XPath expression
node [expression]
where node is a node from the source document’s node tree, and expression is an expression for the condition that the node must fulfill. _________________________

 

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

 49. 

In 1998, in an effort to overcome limitations of CSS and provide a more robust method of displaying XML data, the W3C began developing the
a.
XSL.
b.
XSL-FO.
c.
XSLT.
d.
XPath.
 

 50. 

____ allows you to transform your XML data into a variety of formats.
a.
XMLT
b.
XSL
c.
HTML
d.
Java
 

 51. 

XSL is composed of ____ parts.
a.
two
b.
three
c.
six
d.
eleven
 

 52. 

____ is used to implement page layout and design.
a.
CSLT
b.
XPath
c.
XMLO
d.
XSL-FO
 

 53. 

____ is used to transform XML content into another presentation format.
a.
XPath
b.
XSL-FO
c.
XSLT
d.
XMLO
 

 54. 

____ is in development and has applications and minimal support at this time.
a.
XSL-FO
b.
XPath
c.
XMLO
d.
XSLT
 

 55. 

An XSLT style sheet contains ____ that correspond to the XSLT style sheet language.
a.
processing instructions
b.
attributes
c.
elements
d.
All of the above
 

 56. 

It is customary to distinguish an XSLT style sheet document from other XML documents by using the file extension ____.
a.
.xsl
b.
.xcs
c.
.css
d.
.xst
 

 57. 

An XSLT style sheet converts a source document of XML content into a ____ document.
a.
result
b.
processor
c.
client
d.
server
 

 58. 

In a server-side transformation, the server applies the style sheet to the source document and returns the ____ document to the client--often as a new file.
a.
processor
b.
result
c.
client
d.
server
 

 59. 

____ is included with Internet Explorer 5.0 and above.
a.
Saxon
b.
Xalan
c.
MSXML
d.
All of the above
 

 60. 

Which of the following is a client-side XSLT processor?
a.
xt
b.
Saxon
c.
Xalan
d.
All of the above
 
 
studyguide06_files/i0660000.jpg
 

 61. 

What is the name of the style sheet in the figure above?
a.
stock.xsl
b.
text/xsl
c.
portfolio
d.
1.0
 

 62. 

The root element of an XSLT style sheet is
a.
<stylesheet>.
b.
<transform>.
c.
<node>.
d.
Either A or B
 

 63. 

The default version number of XSLT is ____.
a.
0.0
b.
1.0
c.
2.0
d.
3.5
 

 64. 

The XSLT namespace is associated with a namespace prefix of ____.
a.
sl
b.
xs
c.
xsl
d.
xslt
 

 65. 

Under XPath, each component in a document is referred to as a(n)
a.
node.
b.
tree.
c.
element.
d.
space.
 

 66. 

Under XPath, the entire structure of the document is a node
a.
root.
b.
tree.
c.
index.
d.
space.
 

 67. 

The root ____ refers to the XML document itself.
a.
tree
b.
root
c.
node
d.
index
 

 68. 

A node that contains other nodes is called a ____ node.
a.
container
b.
catalog
c.
roster
d.
parent
 

 69. 

Nodes contained in the parent are called ____ nodes.
a.
child
b.
offspring
c.
progeny
d.
daughter
 

 70. 

Nodes that share a common parent are called ____ nodes.
a.
brother
b.
sibling
c.
sister
d.
family
 

 71. 

Any node found at a level below another node is referred to as a(n) ____ of that node.
a.
ancestor
b.
child
c.
descendant
d.
offspring
 

 72. 

The node at the top of the branch is referred to as the ____ of all nodes that lie beneath it.
a.
descendant
b.
parent
c.
child
d.
ancestor
 

 73. 

The node that stores element attributes is called a(n) ____ node.
a.
attribute
b.
container
c.
storage
d.
stock
 

 74. 

A node for an element is called a(n) ____ node.
a.
attribute
b.
element
c.
named
d.
root
 

 75. 

You can avoid listing all the levels of the node tree by using a(n)
a.
series of ampersands.
b.
pair of question marks.
c.
double forward slash.
d.
All of the above
 

 76. 

With a relative path, the location of the node is indicated relative to a specific node in the tree called the ____ node.
a.
absolute
b.
referential
c.
integral
d.
context
 

 77. 

In describing an absolute path, XPath begins with the root node, identified by a(n) ____ and proceeds down the levels of the node tree.
a.
forward slash
b.
ampersand
c.
colon
d.
apostrophe
 

 78. 

XPath allows you to refer to groups of nodes by using the wildcard character, ____.
a.
&
b.
*
c.
%
d.
$
 

 79. 

To select all of the nodes in the node tree, you can use the path: ____.
a.
++*
b.
&&%
c.
//*
d.
##@
 

 80. 

To select any attribute node in the tree, use the path: ____.
a.
++*
b.
&&%
c.
//*
d.
//@*
 

 81. 

What is the syntax for selecting a text node?
a.
text()
b.
node()
c.
node(text)
d.
text(node)
 

 82. 

If you use XSLT to create an HTML file, any HTML tags in the style sheet are considered ____ result elements because they are ignored by the XSLT processor and sent directly to the result document.
a.
referential
b.
literal
c.
absolute
d.
contextual
 

 83. 

All HTML attribute values must be enclosed in
a.
parentheses.
b.
brackets.
c.
quotes.
d.
Any of the above
 

 84. 

To have complete control over how the processor formats the source document, you can specify the output method using the XSLT element, ____, where attributes are the attributes that define the output format of the result document.
a.
<xsl:print attributes />
b.
<xsl:format attributes />
c.
<xsl:control attributes />
d.
<xsl:output attributes />
 

 85. 

The ____ attribute of the <xsl:output /> element defines the output format using one of the following values: xml, html, or text.
a.
method
b.
format
c.
output
d.
display
 

 86. 

The ____ attribute of the <xsl:output /> element sets the MIME type of output.
a.
MIME
b.
media-type
c.
output
d.
encoding
 

 87. 

What format can be used where the code of the result document follows neither the HTML nor the XML syntax?
a.
DOC
b.
XLS
c.
RTF
d.
PPT
 

 88. 

XSLT provides built-in templates for
a.
comments.
b.
namespaces.
c.
processing instructions.
d.
All of the above
 

 89. 

The XPath syntax for attribute values is
a.
@attribute.
b.
#attribute.
c.
&attribute.
d.
*attribute.
 

 90. 

XSLT provides the ____ element for use in specifying a different sort order than the default.
a.
<xsl:order>
b.
<xsl:sort>
c.
<xsl:rank>
d.
<xsl:arrange>
 

 91. 

The <xsl:sort> element can be used with the ____ element.
a.
<xsl:apply-templates>
b.
<xsl:for-each>
c.
<xsl:choose>
d.
Either A or B
 

 92. 

Which of the following is a conditional element supported by XSLT?
a.
<xsl:when>
b.
<xsl:while>
c.
<xsl:choose>
d.
<xsl:maybe>
 

 93. 

The ____ comparison operator tests whether two values are unequal.
a.
!=
b.
<<
c.
>>
d.
>=
 

 94. 

The ____ comparison operator test whether one value is less than or equal to another.
a.
>=
b.
&lt;=
c.
<=
d.
<<=
 

 95. 

You can reverse the true/false value of an expression using the ____ function.
a.
reverse()
b.
true()
c.
not()
d.
other()
 

 96. 

Which of the following expressions would you use to process only the first node from a branch of the node tree?
a.
1_node
b.
node*1
c.
[1]
d.
node[1]
 

 97. 

Which of the following expressions would you use to process only the last node from a branch of the node tree?
a.
node(last)
b.
node[last()]
c.
node[last]
d.
node_last
 

 98. 

The tag <xsl:element name= “stocks” /> creates the following element in the result document: ____.
a.
<stocks>
b.
<name=stocks>
c.
<”stocks”>
d.
<stocks />
 

Completion
Complete each sentence or statement.
 

 99. 

XSL stands for ___________________________________.
 

 

 100. 

XSL-FO stands for ________________________________________.
 

 

 101. 

XSLT stands for ___________________________________.
 

 

 102. 

To use XSLT, you must create an XSLT ____________________ that contains instructions for transforming the contents of an XML document into another format.
 

 

 103. 

An XSLT style sheet converts a(n) ____________________ document of XML content into a result document.
 

 

 104. 

To transform a source document into a result document, you need an XSLT ____________________.
 

 

 105. 

In a(n) ____________________ transformation, the serve receives a request from a client to generate the result document.
 

 

 106. 

In a(n) ____________________ transformation, a client requests retrieval of both the source document and the style sheet from the server.
 

 

 107. 

At the top of the node tree is the root ____________________.
 

 

 108. 

The text contained in an element node is treated as a(n) ____________________.
 

 

 109. 

A(n) ____________________ is a collection of elements that define how a particular section of the source document should be transformed in the result document.
 

 

 110. 

Since the root node refers to the entire document, the root ____________________ sets up the initial code for the result document.
 

 

 111. 

____________________ elements are those elements that are part of the XSLT namespace and are used to send commands to the XSLT processor.
 

 

 112. 

A(n) ____________________ result element is text sent to the result document, but not acted upon by the XSLT processor.
 

 

 113. 

Sometimes programmers only need a piece of an XML document consisting of a few elements or attributes, called an XML ____________________.
 

 

 114. 

When no template has been defined for the context node or a descendant, the XSLT processor applies one of the ____________________ templates to the node.
 

 

 115. 

By default, nodes are processed in ____________________ order, the order in which they appear in the document.
 

 

 116. 

The = symbol is an example of a comparison ____________________ used to compare one value to another.
 

 

 117. 

____________________ are XPath expressions that test for a condition and create subsets of nodes that fulfill that condition.
 

 

Matching
 
 
Identify the letter of the choice that best matches the phrase or definition.
a.
XSL-FO
e.
parent node
b.
XPath
f.
sibling node
c.
XSLT
g.
ancestor
d.
node
h.
descendant
 

 118. 

A node that shares a common parent with another
 

 119. 

Each component in the document, under XPath
 

 120. 

A node that contains other nodes
 

 121. 

In a node tree, any node found at a level below another node
 

 122. 

The node at the top of the branch of the node tree, with respect to all the nodes beneath it
 

 123. 

Used to implement page layout and design
 

 124. 

Used to transform XML content into another presentation format
 

 125. 

Used to locate information from an XML document and perform operations and calculations upon that content
 



 
Check Your Work     Reset Help