alert("本频道最多"+countPage+"页"); else
location.href = url+str; }
</script>
取图片轮播
判断是否有图片附件:where="wcmchnldoc.attachpic=1 or wcmchnldoc.attachpic=3"
设为首页、加为收藏 <a title="设为首页" onclick="this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.csdn.net');" href="javascript:;">设为首页</a>
<a href="#" onclick="addfavorite()">加为收藏</a> <script>
function addfavorite() {
if (document.all) {
window.external.addFavorite('http://xx.shao.ac.cn','收藏夹'); }
else if (window.sidebar) {
window.sidebar.addPanel('上海天文台信息计算中心', 'http://xx.shao.ac.cn', ""); } }
</script>
细览取附件/相关文档(判断有无附件)
<table width="96%" border="0" align="center" cellpadding="1" cellspacing="1" class="fj_table margin10" id="hidden"> <tr>
<th>附件</th> </tr>
<tr><td><TRS_Appendix INDEX="-1" mode="file" autolink="true" UPLOAD="true"
SEPERATOR="" ENDHTML ="</td></tr>" BEGINHTML="<tr><td width='100%'>" /></td></tr> </table>
<script type="text/javascript">
var app = '<TRS_Appendix index="0" mode="file" field="_recurl" />'; if (app != ''){
document.getElementById("hidden").style.display = "block"; }else{
document.getElementById("hidden").style.display="none"; }
</script>
<table width="96%" border="0" align="center" cellpadding="1" cellspacing="1" class="fj_table" id="hidden1"> <tr>
<th>相关文档</th> </tr>
<trs_relnews mode="all"> <tr>
<td><a href="<trs_document field='_recurl'/>"><trs_document
field="doctitle" autolink="false"/></a></td> </tr>
</trs_relnews>
<script type="text/javascript">
var doc = '<trs_relnews mode="all"><trs_document field="doctitle"
autolink="false"/></trs_relnews>'; if (doc != ''){
document.getElementById("hidden1").style.display = "block"; }else{
document.getElementById("hidden1").style.display="none"; }
</script>
</table>
取文档所有附件
<div id="hidden" class="fujian"> <table width="960" border="0"
cellpadding="0" cellspacing="0" style="margin-bottom:16px;border:1px solid #83D2F6;"> <tr> <td w
idth="960" height="25" background="../../../images/xcv.gif" bgcolor="#FFFFFF"><img src="../../../images/fj.gif" width="102" height="25" /></td> </tr> <tr> <td align="left" valign="top" bgcolor="#FFFFFF"> <table width="950" border="0" cellspacing="0" cellpadding="0" > <trs_appendix index='-1' autolink='true' mode='file' beginhtml="<tr><td width='950' height='25' class='dtcy12' align='left'>" SEPERATOR="" endhtml='</td></tr>' ></trs_appendix> </table> </td> </tr> </table>
<script type="text/javascript"> var app = '<TRS_APPENDIX INDEX="0" FIELD="_recurl"
MODE="file"></TRS_APPENDIX>'; if (app != ''){
document.getElementById("hidden").style.display = "block"; }else{
document.getElementById("hidden").style.display="none"; }
</script> </div>
相关链接,js select选中页面跳转
<select onchange="window.open(this.options[selectedIndex].value)" >
<trs_documents id="相关链接" > <option value="<trs_document field='_recurl'/>"><trs_document
field="doctitle" autolink="false"/></option> </trs_documents> </select>
<trs_condition condition="@subdoctitle"> <h3><trs_document field="subdoctitle" autolink="false">副标题</trs_document></h3> </trs_condition> <trs_condition condition="@SUBDOCTITLE" operator="blank" not="true"> <h3><trs_document field="subdoctitle" autolink="false">副标题</trs_document></h3> </trs_condition>
显示当前正文列表的图片(从第2张开始) <trs_contimgs id="owner" onlyfrom="content" startpos="1">
<img src="<trs_contimg field='url'/>" /> </trs_contimgs>
<script>
//分析当前页面的高度
function resetFrameHeight(){
var hh = document.body.scrollHeight;
parent.document.getElementById("PL_LIST_FRAME").height= hh ; }
</script> </head>
PL_LIST_FRAME是IFRAME的ID
在<body onload="resetFrameHeight()">
访问量统计:<script src="http://count.cas.cn/?siteid=tpd.ihep.cas.cn" ignoreapd="1"></script> 修改siteid域名