|
这段代码只显示一张。我想改成四张 如何改代码呀。哪位朋友能帮帮我呀?非常感谢
<!--#include file="conn.asp"-->
<!--#include file="kw.asp"-->
<html>
<head>
<title>公司产品分类报价管理系统v2.0</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="style/style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.STYLE1 {color: #7e1c19}
.STYLE3 {color: #000000}
-->
</style>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table border="0" width="750" cellspacing="0" cellpadding="0" align="center">
<!-- Header -->
<tr>
<td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0" height="55">
<tr>
<td width="27%" style="padding-left:20px;"><img border="0" src="img/top_logo.gif"></td>
<td width="73%" class="p12" align="right" valign="bottom" style="padding-bottom:8px;padding-right:15px;"><a class="top" href="index.asp">首 页</a> |
联系我们</td>
</tr>
</table></td>
</tr>
<tr>
<td width="100%"><img border="0" src="img/top_pic.gif" width="750" height="14"></td>
</tr>
<tr>
<td width="100%" background="img/middle_pic_bg.gif" align="center"><table border="0" width="738" cellspacing="0" cellpadding="0" align="center">
<tr>
<td width="0" valign="top"><!-- Menu -->
</td>
<td width="738" valign="top" background="img/middle_pic_bg.gif"><!-- Content -->
<table border="0" width="736" cellspacing="0" cellpadding="0">
<tr>
<td width="736" background="img/to_bj.jpg" class="p12" style="padding-left:20px;color:#747474;" height="28"> <a href="index.asp">所有产品</a> > <span class="STYLE3">产品分类</span></td>
</tr>
<tr>
<td width="736" valign="top" background="img/bg.gif"><table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td width="55%"> </td>
<form action="search.asp" style="background-color: #C0C0C0">
<td width="36%" valign="middle" background="img/bg_header_aurora.jpg"><p align="left">
<input type="text" name="search" class="goto" size="24">
<select name="select1" class="goto" id="select1" size="1" style="background-color: #C0C0C0">
<option value="1" selected>产品名称</option>
<option value="2">产品价格</option>
</select>
</td>
<td width="9%" background="img/bg_header_aurora.jpg"><p align="left">
<input type="submit" name="Submit" class="goto" value="搜索">
</td>
</form>
</tr>
<tr>
<td colspan="3" class="td1"><table border="0" width="100%" cellspacing="6" cellpadding="0">
<tr>
<td width="100%" class="p12" height="40"><div align="center">
<%
dim aa1,aa2
aa1=trim(Request("a1"))
if aa1<>"" then
aa1="全部"
end if
aa2=request("a2")
pname2=trim(Request("keyword"))
if pname2<>"" then
d=" and name like '%"&pname2&"%' "
end if
bid=request("bid")
if bid<>"" then
c="and nbigarea="&bid&" "
end if
sid=request("sid")
if sid<>"" then
c="and nsmallarea="&sid&" "
end if
set rs=server.createobject("adodb.recordset")
if session("user")="" then
rs.open "select * from product where new=false "&c&" "&d,conn,1,1
else
rs.open "select * from product where "&c&" "&d,conn,1,1
end if
if rs.recordcount=0 then
%>
<table border="0" cellspacing="0" cellpadding="5" align="center">
<tr>
<td width="436" align=center><img src="img/logo_shibai.gif" width="51" height="56"><br>
暂时没有您想要的产品报价,也许我们正在整理中,请过会再来!</td>
</tr>
</table>
<div align="left">
<% else %>
</font>
<%
rs.PageSize =20'每页记录条数
iCount=rs.RecordCount'记录总数
iPageSize=rs.PageSize
maxpage=rs.pageCount
page=request("page")
if Not IsNumeric(page) or page="" then
page=1
else
page=cint(page)
end if
if page<1 then
page=1
elseif page>maxpage then
page=maxpage
end if
rs.AbsolutePage=Page
if page=maxpage then
x=iCount-(maxpage-1)*iPageSize
else
x=iPageSize/2
end if
For i=1 To x
if rs.EOF or rs.BOF then exit for
%>
</div>
<table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolorlight=#cccccc bordercolordark=#ffffff>
<tr>
<td><div align="left">
<!--#include file="shangping_j.asp"-->
</div></td>
</tr>
<tr>
<td><div align="center">
<%
rs.movenext
if rs.eof then
response.write "<td align=center> </td></tr>"
end if
if rs.EOF or rs.BOF then exit for
%>
<!--#include file="shangping_j.asp"-->
</div></td>
</tr>
</table>
<%
rs.movenext
next
call PageControl(iCount,maxpage,page,"border=0 align=center","<p align=center>")
end if
rs.close
set rs=nothing
Sub PageControl(iCount,pagecount,page,table_style,font_style)
'生成上一页下一页链接
Dim query, a, x, temp , p
p=2
action = "http://" & Request.ServerVariables("HTTP_HOST") & Request.ServerVariables("SCRIPT_NAME")
query = Split(Request.ServerVariables("QUERY_STRING"), "&")
For Each x In query
a = Split(x, "=")
If StrComp(a(0), "page", vbTextCompare) <> 0 Then
temp = temp & a(0) & "=" & a(1) & "&"
End If
Next
Response.Write("<table " & Table_style & ">" & vbCrLf )
Response.Write("<form method=get onsubmit=""document.location = '" & action & "?" & temp & "Page='+ this.page.value;return false;""><TR>" & vbCrLf )
Response.Write("<TD align=right><br>" & vbCrLf )
Response.Write(font_style & vbCrLf )
if page<=1 then
Response.Write (" <IMG height=21 src=images/point_left.gif width=19 style=vertical-align:bottom > " & vbCrLf)
Response.Write ("<IMG height=21 src=images/prev.gif style=vertical-align:bottom width=47>" & vbCrLf)
else
Response.Write("<A href=" & action & "?" & temp & "Page=1><IMG height=21 style=vertical-align:bottom;border:0 src=images/point_left.gif width=19></A> " & vbCrLf)
Response.Write("<A href=" & action & "?" & temp & "Page=" & (Page-1) & "><IMG style=vertical-align:bottom;border:0 height=21 src=images/prev.gif width=47></A> " & vbCrLf)
end if
Response.Write(" 页码:" & page & "/" & pageCount & "页" & vbCrLf)
Response.Write(" 共 " & iCount & " 条记录 " & vbCrLf)
if page>=pagecount then
Response.Write ("<IMG height=21 src=images/next.gif width=46 style=vertical-align:bottom > " & vbCrLf)
Response.Write ("<IMG height=21 src=images/point_right.gif width=18 style=vertical-align:bottom > " & vbCrLf)
else
Response.Write("<A href=" & action & "?" & temp & "Page=" & (Page+1) & "><IMG height=21 src=images/next.gif width=46 style=vertical-align:bottom;border:0 > </A> " & vbCrLf)
Response.Write("<A href=" & action & "?" & temp & "Page=" & pagecount & "><IMG height=21 style=vertical-align:bottom;border:0 src=images/point_right.gif></A> " & vbCrLf)
end if
Response.Write("</TD>" & vbCrLf )
Response.Write("<td valign='bottom'> <select name='select' onChange='category(this.options[this.selectedIndex].value)'>")
Response.Write("<option value=1 select>1</option>")
do while p<=pageCount
Response.Write("<option value='"&p&"'>"&p&"</option>")
p=p+1
loop
Response.Write("</select></td>")
Response.Write("</TR></form>" & vbCrLf )
Response.Write("</table>" & vbCrLf )
End Sub
%>
</div> </tr>
<tr>
<td valign="top" class="p12"><table width="94%" border="0" cellspacing="0" cellpadding="10">
<tr>
<td width="74%" height="20" align="right" valign="bottom"><div align="left"><span class="STYLE1"> 版权所有:凡夫俗子---湖哥|技术支持:<a href="http://www.joinpro.com.tw/james/" target="_blank">(QQ:49566906)</a> | <a href="http://www.miibeian.gov.cn" target="_blank" class="pro">粤ICP备:00000001号</a></span></div></td>
<td width="3%" align="left" valign="top"></td>
<td width="23%" align="left">
<select name="links_url" onChange="links_url(document.all['links_url'].options[document.all['links_url'].selectedIndex].value)">
<option>--友情链接--</option>
<%
set rs = server.CreateObject("adodb.recordset")
rs.open "select * from links order by top",conn,1,1
do while not rs.eof or err
%>
<option value="<%=rs("url")%>"><%=rs("name")%></option>
<%
rs.movenext
loop
rs.close
set rs=nothing
%>
</select></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
<tr>
<td colspan="3"></td>
</tr>
</table></td>
</tr>
<tr>
<td width="736"><img border="0" src="img/botuom_bj.jpg" width="736" height="9"></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
</table>
<table border="0" width="750" cellspacing="0" cellpadding="0" align="center">
<!-- Footer -->
<tr>
<td width="100%" height="37" background="img/bottom_pic.gif"><table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td width="78%" class="p12" style="padding-left:15px;color:#8c8c8c;"><a class="top" href="index.asp">首 页</a> | 联系我们</td>
<td width="22%" class="p11" align="center"></td>
</tr>
</table></td>
</tr>
<tr>
<td width="100%" class="p10" height="25" style="color:gray;padding-left:10px;"> Copyright © 2007 James CPLS Ver2.0, All Rights Reserved.</td>
</tr>
</table>
<p> </p>
</body> |
|