文章分类 | 推荐文章 | 最新文章 | 热点文章 | 最新软件 | 精品软件 | 下载排行 | 推荐下载 | 免费看大片 | WPS | 杀毒软件
清风网络
首 页 软件下载 网络学院 数码学院
QQ 电脑入门 游戏 操作系统 图形处理 办公软件 媒体动画 精文荟萃 工具软件 网络编程 程序开发 网络技术 认证考试 网站建设 文章专栏
当前位置:清风网络学院网站建设HtmlHTML Just Passing Through
精品推荐
特别推荐
·用CSS控制浏览器的滚动条
·marquee标记的用法
·HTML语言:什么是Unicode 什么是UTF-8
·XHTML编写网页代码的七条基本规范
·HTML和XHTML的区别
·HTML语言:什么是Unicode?什么是UTF-8?
·HTML 和 XHTML 区别
·HTML标记全集
·分析比较:三种简洁的Tab导航简析
·HTML教程-HTML简介
·网页Web标准化教程关于表格的应用
·网页代码常用小技巧总结续,网页制作学习
·HTML 标记参考手册
·用htc实现html编辑器
·HTML 4.0 语言快速入门参考教程
·初学:什么是DIV+CSS?有什么优势?
·网页制作实例CSS用一张图片实现圆角
·DIV CSS网页布局学习中容易出现的问题汇总
·HTML标签语义 科学合理的运用HTML标签
·53个CSS-不可或缺的技巧
热点TOP10
·弹出窗口代码集萃
·html教学+HTML语法大全
·图片左右循环连续滚动代码,解决marquee的留白问题
·网页设计基础:Div+CSS布局入门教程
·下拉列表框1下拉列表框2(HTML版)
·HTML标记全集
·解析Html页面:HTML Parser的试用
·在HTML网页中添加WMV格式播放器代码
·中国地区三级联动下拉菜单代码和示例(附带代码下载)
·53个CSS-不可或缺的技巧
·HTML 标记参考手册
·页面显示问题
·用层模拟下拉列表框
·CSS标准网页设计UL和DIV使用的技巧总结
·可移动层的实现示例
·CSS 制作的三级菜单特效代码
·兼容标准XHTML的浮动层特效实现
·HTML及XML语言的转义字符
·HTML 4.0 语言快速参考
·分析比较:三种简洁的Tab导航简析

HTML Just Passing Through

日期:2007年4月27日 作者: 查看:[大字体 中字体 小字体]



  XML's many applications include one traditionally handled by HTML,
document source. Sometimes you want to include some HTML in your XML
source; particularly when styling your XML with XSL to HTML, you may
want some literal HTML in the output. In some cases, you'd just like to
include some well-formed mixed-content HTML in your XML, and not worry
too much about controlling its structure.

Writing explicit XSL rules for each HTML tag would be tedious and hard
to maintain. This week, I'll present a quick shortcut that allows you
to include arbitrary mixed-content HTML in your XSL stylesheet's output.

The XSL stylesheet's input includes some XML document, constrained by
(that is, validated against) a particular DTD. To define the element
containing the arbitrary HTML's content model, simply define content
models for each of the HTML elements you want to use and their
attribute lists. For example, define the <a?tag for hyperlinks like
this:

?!ELEMENT a (#PCDATA)*?BR>
?!ATTLIST a
href CDATA #IMPLIED
target CDATA #IMPLIED
name CDATA #IMPLIED?BR>
(This example is simplified, since it allows only unformatted text
inside the hyperlink text node.) Create a definition like this for each
HTML tag you wish to use. After you've defined the tags, define a
parameter entity that includes all of the HTML "pass-through" tags
you've defined:

?!ENTITY % HTMLpassthru
"aibcodebrtrtdthimgfontem"?BR>
Anywhere in the DTD you want to include mixed-content HTML, use this
parameter entity in the DTD. For example:

?!ELEMENT HTMLHelpText (#PCDATA%HTMLpassthru;)*?BR>

Now for the stylesheet. Defining a separate rule for each possible
HTML element within a HTMLHelpText element would be extremely tedious.
Fortunately, a single rule can handle all such elements. Define an XSL
rule that matches the tag name AND uses <xsl:copy-of?to copy the
entire node (including attributes) to the output.

?!-- EXAMPLE XSL stylesheet --?BR>
?xsl:template
match="aibcodebrtrtdthimgfontem"?BR> ?xsl:copy-of select="."/?BR> ?/xsl:template?BR>

[1] [2] 下一页 




上一篇:HTML教程-多窗口页面(Frames)

下一篇:HTML to XHTML Converter

HTML Just Passing Through 相关文章:
·html教学+HTML语法大全
·下拉列表框1下拉列表框2(HTML版)
·HTML标记全集
·解析Html页面:HTML Parser的试用
·在HTML网页中添加WMV格式播放器代码
·HTML 标记参考手册
·兼容标准XHTML的浮动层特效实现
·背景图片居中显示(HTML,CSS技巧)
·ASP生成静态HTML文件的几种方法比较
·HTML及XML语言的转义字符
HTML Just Passing Through 相关软件:
·当代研究生英语听说 mp3+html
·HTML Calendar Maker Pro v3.8.5 + 注册机
·Txt2Html V2.6.6 +注册机
·网页HTML加密器(HtmlShip) XP v2.0 注册机
·一个DHTML简单留言本
·HTML Builder XPV5.6
·Txt2HTML v2.3 破解版
·HTML40
·Dirhtml V4.6 汉化版(增强版)
·CoffeeCup HTML Editor 2007 V10.0.0.210

特别声明:本站除部分特别声明禁止转载的专稿外的其他文章可以自由转载,但请务必注明出处和原始作者。文章版权归文章原始作者所有。对于被本站转载文章的个人和网站,我们表示深深的谢意。如果本站转载的文章有版权问题请联系编辑人员,我们尽快予以更正。
[打印本页] [关闭窗口] 转载请注明来源:http://www.viphot.com
| 帮助(?) | 版权声明 | 友情连接 | 关于我们 | 信息发布
Copyright 2007 www.viphot.com All Rights Reserved. 鄂ICP备05000083号Powered by:viphot