⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 index.xsl

📁 XML源码教材,XMLspy2006编制,供给IT爱好者参考学习!
💻 XSL
字号:
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
	<xsl:import href="top.xsl"/>
	<xsl:import href="search.xsl"/>
	<xsl:import href="foot.xsl"/>
	
	<xsl:template match="/">
		<html>
			<head>
				<title>Welcn Blog V1.0 XML+XSL+ASP</title>
				<meta name="robots" content="all"/>
				<meta name="author" content="Welcn Design"/>
				<meta name="copyright" content="Welcn Blog"/>
				<meta name="description" content="Welcn,Photo"/>
				<meta name="keywords" content="Welcn,Photo"/>
				<meta name="DC.title" content="Welcn Photo My life"/>
				<link type="text/css" rel="stylesheet" href="images/css.css"/>
			</head>
			<body>
			
				<div id="global_div">
					<div id="top">
						<xsl:apply-templates select="creatop/top"/>
					</div>
					
					<div class="clear"></div>
					
					<div id="main">
						
						<div class="left" id="item">
							<xsl:apply-templates select="creatop/updata"/>
						</div>
						
						<div class="right" id="tool">
						        <div id="search">
							<div class="title">绔欑偣鎼滅储</div>
							<ul>
							<xsl:apply-templates select="creatop/search"/>
							</ul>
							</div>

						        <div id="cool">
							<div class="title">鎴戠殑鎺ㄨ崘</div>
							<ul>
							<xsl:apply-templates select="creatop/cool"/>
							</ul>
							</div>

							<div id="photo">
							<div class="title">鎴戠殑鐓х墖</div>

							<ul>
							
							<xsl:apply-templates select="creatop/photo"/>
							</ul>
							</div>

							<div id="link">
							<div class="title">鎴戠殑鏈嬪弸</div>

							<ul>
							
							<xsl:apply-templates select="creatop/link"/>
							</ul>
							</div>



						</div>
						
					</div>
					
					<div class="clear"></div>
					
					<div id="foot">
						<xsl:apply-templates select="creatop/foot"/>
					</div>
					
				</div>
				
			</body>
		</html>
	</xsl:template>
	
	<!-- BLOG鏇存柊 -->
	<xsl:template match="creatop/updata">
	<h1>Index</h1>
	<xsl:for-each select="item">
		
		<div class="title">

		<a>
		<xsl:attribute name="href">
		display.asp?id=<xsl:value-of select="id" />
		</xsl:attribute>
		<xsl:value-of select="title" />
		</a>
		</div>
		
		<div class="pubdate">Pubdate : <xsl:value-of select="pubdate"/> | Count : <xsl:value-of select="count"/></div>
		<div class="description"><xsl:value-of select="description"/></div>
		
		
		</xsl:for-each>
	</xsl:template>
	
	
        <!-- BLOG 鎺ㄨ崘 -->
	<xsl:template match="creatop/cool">
		<xsl:for-each select="cool_item">
			<li>
				<a >
					<xsl:attribute name="href">
					display.asp?id=<xsl:value-of select="cool_id"/>
					</xsl:attribute>
					<xsl:value-of select="cool_title"/>
				</a>
			</li>
		</xsl:for-each>
	</xsl:template>


        <!-- 鐓х墖 -->
	<xsl:template match="creatop/photo">
		<xsl:for-each select="photo_item">
			<li>
				<a >
					<xsl:attribute name="href">
					display.asp?id=<xsl:value-of select="photo_url"/>
					</xsl:attribute>
					<img>
					<xsl:attribute name="src">
					upload/<xsl:value-of select="photo_img"/>
					</xsl:attribute>

					<xsl:attribute name="title">
					upload/<xsl:value-of select="photo_img"/>
					</xsl:attribute></img>
				</a>
			</li>
		</xsl:for-each>
	</xsl:template>

	<!-- 杩炴帴 -->
        <xsl:template match="creatop/link">
		<xsl:for-each select="link_item">
			<li>
				<a >
					<xsl:attribute name="href">
					<xsl:value-of select="link_url"/>
					</xsl:attribute>

					<xsl:attribute name="title">
					<xsl:value-of select="link_txt"/>
					</xsl:attribute>
					
					路<xsl:value-of select="link_txt"/>
					

				</a>
			</li>
		</xsl:for-each>
	</xsl:template>
	
	
</xsl:stylesheet>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -