showart_body.asp

来自「功能简介: 1) 首页投票调查系统 2)FLASH导航清新直观(带FLA源文件」· ASP 代码 · 共 67 行

ASP
67
字号
<%sub showart_body()

sql="select * from art where art_id="&request.querystring("art_id")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
%>
<table width="<%=tablewidth%>" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="#FFFFFF">
  <tr> 
    <td colspan="3" height="10">
    <p style="line-height: 200%"></td>
  </tr>
  <tr> 
    <td width="554" valign="top"> 
      <div align="center" >
        <center>
          <table width="98%" border="1" cellspacing="0" cellpadding="6" bgcolor="#F7F7F7" bordercolor="#FFFFFF" style="border-collapse: collapse">
            <tr> 
              <td colspan="2" background="../images/btbg.gif" bgcolor="#CCCCCC" class="chinese"> 
                <div align="center"><b><%=rs("art_title")%></b></div>
                <p style="margin-top:0; margin-bottom:0"> <font color="#808080"></tr>
				<tr><td bgcolor="#FFFFFF" align="center">所属分类:
            <%sql="select cat_id,cat_name from a_cat where cat_id="&rs("cat_id")
		  set rs1=conn.execute(sql)%>
            <a href="article.asp?cat_id=<%=rs1("cat_id")%>"><%=rs1("cat_name")%></a> 
            <%rs1.close
		  set rs1=nothing%>
            更新日期:<%=rs("art_date")%> 阅读次数:<%=rs("art_count")%></td></tr>
            <tr> 
              <td width="554" valign="top" bgcolor="#FFFFFF"><br>&nbsp; <%=ubb2html(formatStr(autourl(rs("art_content"))),true,true)%> 
                <br> <br>
                --------------------------------------------------------------------------------<br> 
                <b>相关文章</b><br> 
                <%sql="select top 5 * from art where art_content like '%"&rs("art_keyword")&"%' and art_id <> "&rs("art_id")&" order by art_date DESC"
			set rs2=server.createobject("adodb.recordset")
            rs2.open sql,conn,1,1
			do while not rs2.eof
            %></font>
                <a href="showart.asp?art_id=<%=rs2("art_id")%>&cat_id=<%=rs2("cat_id")%>"> 
                <font color="#808080"><%=rs2("art_title")%></font></a><font color="#808080"> 
                <%=rs2("art_date")%><br>
                <%
			rs2.movenext
			loop
			if rs2.eof and rs2.bof then
			response.write "没有相关文章"
			end if
			rs2.close
			set rs2=nothing
			%>
                </font> </td>
            </tr>
          </table>
        </center>
      </div>
      <p style="line-height: 200%">
      <br>
    </td>
    <td width="1" background="images/dotlinev.gif"></td>
    <td width="205" align="center" valign="top"> 
      <%call articlecat()%>
    </td>
  </tr>
  <tr> 
    <td colspan="3" background="images/dotlineh.gif" height="1"></td>
  </tr>
</table>
<%end sub%>

⌨️ 快捷键说明

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