-
Notifications
You must be signed in to change notification settings - Fork 32
Expand file tree
/
Copy pathIndent.xsl
More file actions
26 lines (26 loc) · 784 Bytes
/
Indent.xsl
File metadata and controls
26 lines (26 loc) · 784 Bytes
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
<?xml version="1.0" encoding="euc-kr"?>
<!-- -->
<!-- indent for XSLT (ver 0.1.2) -->
<!-- Last Update : 2002.09.25 -->
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" encoding="euc-kr" indent="yes"/>
<xsl:template match="*">
<xsl:element name="{name(.)}">
<xsl:apply-templates select="@*"/>
<xsl:if test="child::* or child::text()">
<xsl:apply-templates/>
</xsl:if>
</xsl:element>
</xsl:template>
<xsl:template match="@*">
<xsl:attribute name="{name(.)}"><xsl:value-of select="."/></xsl:attribute>
</xsl:template>
<xsl:template match="processing-instruction()">
<xsl:copy-of select="."/>
</xsl:template>
<xsl:template match="comment()">
<xsl:comment>
<xsl:value-of select="."/>
</xsl:comment>
</xsl:template>
</xsl:stylesheet>