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

📄 theindex.xsl

📁 蓝丽Net留言系统说明手册 1:蓝丽Net留言系统亮点提示 蓝丽Net留言系统虽然开发的时间较短
💻 XSL
字号:
<?xml version='1.0' encoding='gb2312'?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">
<xsl:template match="/">
<HTML xmlns:v="Lshdic2004 for editing the VML">
<HEAD>
<META http-equiv="Content-Type" content="text/html; Charset=gb2312"/>
<META name="GENERATOR" content="网络程序员伴侣(Lshdic)2004_星钻超爽版"/>
<TITLE><xsl:value-of select="document/@title"/></TITLE>
<style>
v\:*{behavior:url(#default#VML);}  <!--声明一个VML对象应用于页脚-->
*{font-size:12px;font-family:宋体}
a{color:maroon;text-Decoration:none;}
a:hover{color:blue;text-Decoration:underline;}
</style>
</HEAD>
<BODY topmargin="5">
<BASE target="_blank"/>
<script>
function open1(url1){
left1=screen.width/2-250;top1=screen.height/2-150
win1=open(url1,"win1","toolbar=0,scrollbars=0,width=500,height=300,left="+left1+",top="+top1);
win1.focus();
return void(0);
}
</script>
<form method='post' action='index.aspx' id='c' target="_top">
<TABLE rules="all" bordercolorlight='bbbbbb' bordercolordark='dddddd' align="center" width="620" cellspacing="0" cellpadding="5" style='border-Collapse:collapse;border:0;border-top:1 solid black;border-left:1 solid black;border-right:1 solid black'>
<tr>
<td bgcolor="#619CE7" style='color:white;border-bottom:1 solid black;padding:3' colspan="4">
<center><b><xsl:value-of select="document/@title"/> 
<xsl:choose>
<xsl:when test="document/@admin[.='False']">
<a href='admin.aspx' style='color:white' target='_top'>进入管理员模式</a>
</xsl:when>
<xsl:otherwise>
<a href='admin.aspx?exit=true' style='color:white' target='_top'>退出管理模式</a>
</xsl:otherwise>
</xsl:choose>
</b></center>
</td>
</tr>
<tr align="center"><td width="120">作者</td><td width="420">留言主题(<a href='addnew.aspx' style='text-Decoration:underline;' target='_top'>发表新留言</a>)</td><td width="50">已回复</td><td width="30"><a href='javascript:confirm("站长,您确实要删除所选的留言?")?c.submit():void(0);void(0)' style='color:navy;text-Decoration:underline;' target="_top">删除</a></td></tr>
<xsl:for-each select="document/record">
<tr>
<td style='color:maroon'><xsl:value-of select="liuyanzuozhe"/><p/><font color='gray'>性别(<xsl:value-of select='sex'/>)</font></td>
<td>
<xsl:element name='a'>
<xsl:attribute name='href'>javascript:open1("showmessage.aspx?messageid=<xsl:value-of select="id"/>");</xsl:attribute>
<xsl:attribute name='target'>_top</xsl:attribute>
<xsl:value-of select="title"/>
</xsl:element>
<xsl:if test="noopen[.='True']"><font color='aaaaaa' lshdic="仅站长(验证后)可阅" style='cursor:hand;margin-left:-5'>(不公开)</font></xsl:if>
<p/>
<div align="right" style='color:gray'>
<xsl:value-of select="dates"/>
<xsl:if test="homepage[.!='']">
<xsl:element name='a'><xsl:attribute name='style'>color:gray</xsl:attribute><xsl:attribute name='href'><xsl:value-of select="homepage"/></xsl:attribute>主页</xsl:element> 
</xsl:if>
<xsl:if test="email[.!='']">
<xsl:element name='a'><xsl:attribute name='style'>color:gray</xsl:attribute><xsl:attribute name='href'>mailto:<xsl:value-of select="email"/></xsl:attribute><xsl:attribute name='target'>_top</xsl:attribute>邮箱</xsl:element> 
</xsl:if>
<xsl:if test="oicq[.!='']">
<xsl:element name='a'><xsl:attribute name='style'>color:gray</xsl:attribute><xsl:attribute name='href'>javascript:alert("The user OICQ is: <xsl:value-of select="oicq"/>");void(0)</xsl:attribute><xsl:attribute name='target'>_top</xsl:attribute>OICQ</xsl:element> 
</xsl:if>
<xsl:if test="address[.!='']">
<xsl:element name='a'><xsl:attribute name='style'>color:gray</xsl:attribute><xsl:attribute name='href'>javascript:alert("This anthor comes from: <xsl:value-of select="address"/>");void(0)</xsl:attribute><xsl:attribute name='target'>_top</xsl:attribute>来自</xsl:element> 
</xsl:if>
</div>
</td>
<td align="center">
<xsl:choose>
<xsl:when test="reply[.='False']">NO</xsl:when>
<xsl:otherwise><font color='red'>YES</font></xsl:otherwise>
</xsl:choose>
<xsl:if test="../@admin[.='True']">
<p/>
<xsl:element name='a'><xsl:attribute name='href'>admin.aspx?reply=<xsl:value-of select="id"/></xsl:attribute><xsl:attribute name='target'>_top</xsl:attribute>回复</xsl:element>
</xsl:if>
</td>
<td align="center" onclick='if(event.srcElement.tagName=="TD")this.all(0).checked=!this.all(0).checked' style='cursor:hand'>
<xsl:element name='input'><xsl:attribute name='type'>checkbox</xsl:attribute><xsl:attribute name='value'><xsl:value-of select="id"/></xsl:attribute><xsl:attribute name='name'>dels</xsl:attribute></xsl:element>
</td>
</tr>
</xsl:for-each>
<tr><td colspan='4' align='right' style='filter:alpha(opacity=90);background-color:white'><!--开始分页部分,真是够麻烦,注意如果把STYLE部分去掉,将不会启用透明样式(不透明照样具备观赏价值)-->
<base target='_top'/>

<font color='gray'>
<xsl:value-of select="document/usetime"/>,共<xsl:value-of select="document/@allrecord"/>条留言,分为<xsl:value-of select="document/@page"/>/<xsl:value-of select="document/@pagecount"/>页,一页<xsl:value-of select="document/@pagesize"/>条 
</font>

<xsl:choose>
<xsl:when test="document/@page[value()>1]"> <!--value-select不好使,“上页”功能我们用DOM得到数值后-1来实现-->
<a href='index.aspx'>头页</a>
<xsl:element name='a'><xsl:attribute name='href'>index.aspx?page=<xsl:eval>parseInt(this.lastChild.attributes(2).text)-1</xsl:eval></xsl:attribute>上页</xsl:element>
</xsl:when>
<xsl:otherwise>头页 上页 </xsl:otherwise>
</xsl:choose>

<xsl:choose>
<xsl:when test="document/@page[number(.) &lt; number(/document/@pagecount)]">  <!--注意,小于号必须用实体,或使用not(.>pagecount)-->
<xsl:element name='a'><xsl:attribute name='href'>index.aspx?page=<xsl:eval>parseInt(this.lastChild.attributes(2).text)+1</xsl:eval></xsl:attribute>下页</xsl:element>
<xsl:element name='a'><xsl:attribute name='href'>index.aspx?page=<xsl:value-of select="document/@pagecount"/></xsl:attribute>尾页</xsl:element>
</xsl:when>
<xsl:otherwise>下页 尾页</xsl:otherwise>
</xsl:choose>

<textarea id='a' style='display:none'> <!--TNND,小于号及&符号直接写在脚本里总是出错-->
for(i=thepage-2;i&lt;thepage+4;i++){
if(i>0&amp;&amp;i&lt;pagecount+1){
if(i==thepage){document.write("["+i+"]")}else{document.write("&lt;a href='index.aspx?page="+i+"'>["+i+"]&lt;/a>")}
}}
</textarea>
<script>  <!--开始我们的 [1][2][3][4] ,为不影响布局,我们只来实现输出当前页的“前2页”及“后3页”,不难很简单-->
thepage=<xsl:value-of select="document/@page"/>;         //先搞到当前页页码
pagecount=<xsl:value-of select="document/@pagecount"/>;  //在搞到共有多少页,然后……
eval(document.all.a.value)
</script>

<xsl:element name='select'>   <!--原创下拉菜单分页,移植在XSL中实现稍微有点烦琐,循环1万次大约1秒(但使用的不是服务器CPU,若真有万页以上又怕耗时,建议循环时采用“变量+=变量”,也就是HTML数据递加,然后一次性document.write,本人估计会快20多倍,o该休息了,想改进的同志门自己动手)-->
<xsl:attribute name='id'>selpage</xsl:attribute>
<xsl:attribute name='style'>background-color:eeeeee</xsl:attribute>
<xsl:attribute name='onchange'>
if(this.options[this.selectedIndex].text=="GO!"){
str1=prompt("跳转提示:\n请输入一个1-<xsl:value-of select='document/@pagecount'/>的页码!","");
if(str1!=null&amp;&amp;str1!=""&amp;&amp;isNaN(str1)==false){
location.href="index.aspx?page="+str1}else{this.options[1].selected=true}
}else{
location.href="index.aspx?page="+this.options[this.selectedIndex].text}
</xsl:attribute>
<option>GO!</option>
<script>
<xsl:comment>  <!--不加这对标记将无法执行下列JS-->
for(j=1;j&lt;<xsl:value-of select='document/@pagecount'/>+1;j++){document.write("&lt;option>"+j+"&lt;/option>");}
</xsl:comment>
</script>
</xsl:element>
<script>
document.all.selpage.options[<xsl:value-of select='document/@page'/>].selected=true
</script>
</td></tr>
</TABLE>
<center>  <!--页低Vml三维物件设计-->
<v:rect style='position:relative;width:620;height:23;margin-top:-15;margin-left:-1;padding-top:15;z-index:-5'>
<v:fill type='gradient' color='#dddddd'/>
<v:extrusion brightness='0.6' foredepth='32pt' backdepth='25pt' color='#619CE7' on='true'/>
<v:textbox>
<a href='http://www.lshdic.com/download/netbook.rar'>蓝丽Net留言系统</a>1.0,该程序授于[您的网站]免费使用,友情伙伴:<a href='http://www.lshdic.com' target='_blank'>蓝丽网</a>,原作者:<a href='javascript:alert("Anthor(FYW.FengYunWu) QQ:21152530\n\nThe software of Lshdic,The LanLiNet initiates the person\n\nThank friend who have to back me up");void(0)'>风云舞</a>
</v:textbox>
</v:rect>
</center>
</form>
</BODY></HTML>
</xsl:template>
</xsl:stylesheet>

⌨️ 快捷键说明

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