XSL最全基础教程之xsl:attribute-set元素

2025-05-18 06:50:45

1、语法<xsl:attribute-set name = QName use-attribute-sets = QNames></xsl:attribute-set>

2、属性 name(必需): 定义该属性集的名称 use-attribute-sets(可选): 在该属性由空格分隔,集中使用的其它属性集的列表。

3、示例创建一个名为book.xml的XML文件<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="book.xsl"?><book> <chapter> <heading>The First Chapter</heading> </chapter> <chapter> <heading>The Next Chapter</heading> </chapter></book>

XSL最全基础教程之xsl:attribute-set元素

5、测试结果运行XML Tools选择XSL Transformation<?xml 箪滹埘麽version="1.0"?>稆糨孝汶; <fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format" quadding ="start" font-size="12pt" font-weight="bold"> The First Chapter </fo:block> <fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format" quadding ="start" font-size="12pt" font-weight="bold"> The Next Chapter </fo:block>

XSL最全基础教程之xsl:attribute-set元素
声明:本网站引用、摘录或转载内容仅供网站访问者交流或参考,不代表本站立场,如存在版权或非法内容,请联系站长删除,联系邮箱:site.kefu@qq.com。
猜你喜欢