참고 주소 : http://www.w3schools.com/xsl/xsl_w3celementref.asp
<xsl:element>
출력(output)에 새로운 xml element 생성
속성
name = "element name"
namespace = "uri-참조"
<xsl:attribute>
element 내부에 attribute 추가
예시)
XSLT : <name><xsl:attribute name="id">11</xsl:attribute>James</name>
output : <name id="11">James</name>
<xsl:attribute-set>
attribute 그룹을 정의
정의된 그룹은 <xsl:element>의 use-attribute-sets 속성을 이용하여 호출할 수 있다.
<xsl:if><xsl:choose>
조건문 처리
둘 다 test속성을 이용해 논리 표현식이 참이 경우 내용에 대해 해석한다.
<xsl:for-each>
구문 : <xsl:for-each select="(XPath)">
표현식은 test처럼
해당하는 노드에 대하여 반복적으로 탬플릿을 적용하는 효과
<xsl:copy-of>
구문 : <xsl:copy-of select="(XPath)"/>
해당 부분의 subtree 자체를 복사
<xsl:copy>
구문 : <xsl:copy use-attibute-sets = "">
<xsl:sort>
결과를 특정 순서로 정렬
<xsl:for-each>나 <xsl:apply-template>의 자식 노드로만 사용된다.
속성
select : 정렬할 대상
data-type
order : 오름차순/내림차순
'컴퓨터 공부 > XML' 카테고리의 다른 글
[5월 19일 3교시] XSLT 실습 (0) | 2009.05.19 |
---|---|
[5월 19일 2교시] XSLT elements 2 (0) | 2009.05.19 |
[5월 18일 3교시] XSLT 템플릿 (0) | 2009.05.18 |
[5월 18일 2교시] XPath (0) | 2009.05.18 |
[5월 18일 1교시] .NET에서 XML 접근 + XSLT (0) | 2009.05.18 |