-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpopolVuh_to_HTML.xsl
More file actions
57 lines (42 loc) · 1.89 KB
/
popolVuh_to_HTML.xsl
File metadata and controls
57 lines (42 loc) · 1.89 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns="http://www.w3.org/1999/xhtml"
exclude-result-prefixes="xs"
version="3.0">
<xsl:output method="xhtml" encoding="utf-8" doctype-system="about:legacy-compat"
omit-xml-declaration="yes"/>
<xsl:template match="/">
<html>
<head>
<title>Popol Vuh</title>
<link rel="stylesheet" type="text/css" href="mayanStyling.css"/>
</head>
<body>
<xsl:apply-templates select="descendant::popolVuh"/>
<iframe src="godography.html" height="500" width="300" name="Gods" class="iframe"></iframe>
</body>
</html>
</xsl:template>
<xsl:template match="popolVuh">
<h1><xsl:apply-templates select="title"/></h1>
<xsl:for-each select="book"><div class="book">
<xsl:for-each select="part">
<div class="part"><h2><xsl:apply-templates select="head"/></h2>
<p><xsl:apply-templates select="text"/></p></div>
</xsl:for-each>
</div></xsl:for-each>
</xsl:template>
<xsl:template match="book">
<xsl:for-each select="part">
<div class="part"><h2><xsl:apply-templates select="head"/></h2>
<p><xsl:apply-templates select="text"/></p></div>
</xsl:for-each>
</xsl:template>
<xsl:template match="spk">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="character">
<span class="{@idref ! data()}"><a href="godography.html{@idref ! data()}"><xsl:apply-templates/></a></span>
</xsl:template>
</xsl:stylesheet>