문화유산:장소목록.xsl: 두 판 사이의 차이
편집 요약 없음 |
편집 요약 없음 |
||
| 1번째 줄: | 1번째 줄: | ||
<?xml version="1.0" encoding="UTF-8"?> | <?xml version="1.0" encoding="UTF-8"?> | ||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> | <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> | ||
<xsl:template match="/"> | <xsl:template match="/"> | ||
<xsl: | <html> | ||
<head> | |||
<style> | |||
.place-table { width: 100%; border-collapse: collapse; font-family: "Malgun Gothic", serif; } | |||
.place-table td { border: 1px solid #aaa; padding: 15px; text-align: left; } | |||
.place-table th { border: 1px solid #aaa; padding: 15px; background-color: #e8f0f7; color: #2c3e50; text-align: center; } | |||
.name-cell { font-weight: bold; font-size: 1.1em; color: #0054d3; } | |||
.description { margin: 0; padding-left: 20px; color: #2980b9; } | |||
</style> | |||
</head> | |||
<body> | |||
<table class="place-table"> | |||
<tr> | |||
<th width="10%">명칭</th> | |||
<th width="10%">위치</th> | |||
<th width="10%">건립</th> | |||
<th width="70%">설명</th> | |||
</tr> | |||
<xsl:for-each select="/place_list/place"> | |||
<tr> | |||
<!--명칭--> | |||
<td> | |||
<xsl:value-of select="name/korean"/> | |||
<xsl:text>(</xsl:text> | |||
<xsl:value-of select="name/hanja"/> | |||
<xsl:text>, </xsl:text> | |||
<xsl:value-of select="name/english"/> | |||
<xsl:text>) | |||
</td> | |||
<!--위치--> | |||
<td> | |||
<xsl:value-of select="address"/> | |||
<xsl:text> (</xsl:text> | |||
<xsl:value-of select="coordinates/latitude"/> | |||
<xsl:text>, </xsl:text> | |||
<xsl:value-of select="coordinates/longitude"/> | |||
<xsl:text>, </xsl:text> | |||
<xsl:value-of select="coordinates/altitude"/> | |||
<xsl:text>) | |||
</td> | |||
<!--건립--> | |||
<td> | |||
<xsl:value-of select="established/year"/> | |||
<xsl:text> (</xsl:text> | |||
<xsl:value-of select="established/reign_year"/> | |||
<xsl:text>) | |||
</td> | |||
<!--해설--> | |||
<td> | |||
<xsl:for-each select="description/p"> | |||
<xsl:value-of select="."/> | |||
<xsl:if test="position() != last()"> | |||
</xsl:if> | |||
</xsl:for-each> | |||
</td> | |||
</tr> | |||
</xsl:for-each> | |||
</table> | |||
</body> | |||
</html> | |||
</xsl:template> | </xsl:template> | ||
</xsl:stylesheet> | </xsl:stylesheet> | ||
2026년 4월 5일 (일) 12:15 판
<?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
| 명칭 | 위치 | 건립 | 설명 |
|---|---|---|---|
|
|
|
|
|
</xsl:stylesheet>
오류 검사
🔍 XML 유효성 검사기: 문화유산:장소목록.xsl