Your SlideShare is downloading. ×
XSLT
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

XSLT

698
views

Published on

XSLT

XSLT

Published in: Technology, Education

0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
698
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
42
Comments
0
Likes
1
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. <?xml version=„1.0‟ encoding=“UTF-8”?> <html><HumanResource> <head> <title>Human Resource</title> <Person id=„1‟ salary=“500”> </head> <Name> <body> <FirstName>John</FirstName> <p>Joe‟s company have 1 workers</P> <MidName></MidName> <hr/> <LastName>Doe</LastName> <p>Detail information:</p> </Name> <p>Name: John doe</p> <Position>Manager</Position> <p>Position: Manager</p> </Person> </body> </html></HumanResource>
  • 2. <?xml version="1.0"?><xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/TR/REC-html40"> <xsl:output method="html"/> • root node <xsl:template match="/"> • xsl:stylesheet or xsl:transform <html> <head><title>Human Resource</title></head> • specific output <body><p>Joes company have <xsl:value-of select="count(HumanResource/Person)" /> workers</p> <p>Detail information:</p> <hr/> <xsl:apply-templates select="/HumanResource/Person" /> </body> • match root element </html> • call function • main function </xsl:template> • have only one main function <xsl:template match="Person"> • a function <p>Name: <xsl:value-of select="string(Name)" /></p> <p>Position: <xsl:value-of select="Position" /></p> </xsl:template></xsl:stylesheet> • a built-in function
  • 3. literal result XSLTcode
  • 4. Order by import precedenceOrder by priority
  • 5. Import B (5) D (6)Import E (4)Import A (1) Import Import F (3) C (2)