| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 644 人关注过本帖
标题:[求助]怎样在文章显示页里面实现上一篇,下一篇和相关文章功能
只看楼主 加入收藏
lieges
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2008-3-12
收藏
 问题点数:0 回复次数:3 
[求助]怎样在文章显示页里面实现上一篇,下一篇和相关文章功能
我这里有页面代码 可是我想实现一个栏目里得文章内容显示页里的上一篇,下一篇和相关内容显示

<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="inc/includeall.asp"-->
<%
typeid=request("typeid")
info_id=request("info_id")
if typeid = "" then
  message2 "非法访问!","cai.asp"
end if
if info_id = "" then
  message2 "非法访问!","cai.asp"
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title><%=company%></title>
<meta name="keywords" content="<%=keywords1%>" />
<meta name="description" content="<%=descriptions1%>" />
<meta name="author" content="<%=author%>" />
<link href="css/css.css" rel="stylesheet" type="text/css">
</head>

<body>
<!--#include file="head.asp" -->
<table width="800" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="1"></td>
  </tr>
  <tr>
    <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="174" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td valign="top"><!--#include file="left_cai.asp" --></td>
          </tr>

        </table></td>
        <td valign="top"><table width="620" border="0" align="right" cellpadding="0" cellspacing="0">
         
          <tr>
            <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td class="bk_red"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
                    <tr>
                      <td height="25" background="imag/ind_138.jpg"><table width="97%" border="0" align="center" cellpadding="0" cellspacing="0">
                          <tr>
                            <td width="3%"><img src="imag/ind_141.jpg" width="11" height="10" alt=""></td>
                            <td width="87%" class="z6"><%
       if typeid=5 then
           response.Write("曾发表文章")
       elseif typeid=6 then
           response.Write("曾发表相关新闻狂搜")
         if info_id=adostrom.
       end if
       %></td>
                            <td width="10%" align="right">&nbsp;</td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="3"></td>
                    </tr>
                    <tr>
                      <td height="465" valign="top">
                      <%
        rs.open"select* from newhouse where id="&info_id&"",conn,1,3
        housename=rs("housename")
                        rs.update
        %>
        <%
                        rs.open "select * from YT_News where id="&info_id&"",conn,1,3
                        rs("hits")=cint(rs("hits"))+1
                        rs.update
                  %>
                      <table width="90%" border="0" align="center" cellpadding="0" cellspacing="0">
                        <tr>
                          <td>&nbsp;</td>
                        </tr>
                        <tr>
                          <td align="center" class="news"><%=rs("title")%></td>
                        </tr>
                        <tr>
                          <td align="center" class="z15">发表日期:<%=zy_Date3(rs("createdate"))%>&nbsp;&nbsp;&nbsp;&nbsp;来源:<%=rs("from1")%></td>
                        </tr>
                        <tr>
                          <td>&nbsp;</td>
                        </tr>
                        <tr>
                          <td class="hg1"><%=rs("content")%></td>
                        </tr>
                      </table>
                      <%
                        rs.close
                        %>
                      </td>
                    </tr>
                    <tr>
                      <td height="25"></td>
                    </tr>
                </table></td>
              </tr>
            </table></td>
          </tr>
        </table></td>
      </tr>

    </table></td>
</table>
<!--#include file="foot.asp" -->
</body>
</html>
搜索更多相关主题的帖子: request content company include title 
2008-03-12 13:47
lieges
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2008-3-12
收藏
得分:0 
晕3怎么 没一个人回答
2008-03-21 14:48
madpbpl
Rank: 4
等 级:贵宾
威 望:11
帖 子:2876
专家分:244
注 册:2007-4-5
收藏
得分:0 
sql1 ="select top 1 * from YT_News where id<"&info_id&" order by id desc"  '上一篇
sql2 ="select top 1 * from YT_News where id>"&info_id&" order by id asc" '下一篇
2008-03-21 15:02
dhdhzzw
Rank: 1
等 级:新手上路
帖 子:949
专家分:0
注 册:2007-8-13
收藏
得分:0 
好,学习
2008-03-21 16:56
快速回复:[求助]怎样在文章显示页里面实现上一篇,下一篇和相关文章功能
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.025767 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved