3.2xsl: value-ofXSL: value-of is used to write the text values of elements in the source document to the output document. For example, there is an XML document for personal materials :? Xmlversion = "1.0" encoding = "iso-8859-1 "? PERSONnameajie/nameage28/age/PERSON
3.2 xsl: value-
XSL: value-of is used to write the text values of elements in the source document to the output document. For example:
There is an XML document for personal materials:
Ajie
28
If you want to display the name element value in the above XML source document in the output document, you can write the XSLT code as follows:
After performing this operation, you will see that 'ajie' is displayed separately. Match = 'person 'defines the matching PERSON node, xsl: value-
Syntax clarification needs to output the value of a node, while select = 'name' defines the element to be output as name. Check whether this process is similar to querying a person's name in the database? Of course, there are more and more complex xsl: value-of queries. because it involves the functions of searching and locating, we will explain it carefully in the later XPath syntax.
Xsl: copy-of has the same effect, which is not repeated.