-
Notifications
You must be signed in to change notification settings - Fork 0
/
lookpro.asp
178 lines (176 loc) · 5.73 KB
/
lookpro.asp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title></title>
<style type="text/css">
<!--
.style1 {color: #f2ab5b}
.style2 {
color: #f37b54;
font-weight: bold;
font-size: 14pt;
}
.style3 {font-weight: bold}
.style4 {color: #000000}
-->
</style>
<!--#include file="include/conn.asp" -->
<!--#include file="include/include.asp" -->
<%
if request("action")="add" then
if trim(request("comment"))="" then
response.Write("<script>alert('请详细填写!');history.back();</script>")
response.End()
end if
sql="select * from [comment]"
set rs=Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,3,3
rs.addnew
rs("shangpinid")=request("Id")
rs("shijian")=now()
rs("comment")=request("comment")
rs("mingcheng")=request("mingcheng")
rs.update
rs.close
set rs=nothing
response.Write("<script>alert('评论发表成功!');window.location.href='lookpro.asp?id="&request("id")&"';</script>")
end if
%>
<table width="792" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td colspan="3"><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="792" height="165" background="images/index_r1_c1.jpg"><!--#include file="top.asp" --></td>
</tr>
</table></td>
</tr>
<tr>
<td width="197"><!--#include file="left.asp" --></td>
<td width="590" valign="top">
<table border="0" cellpadding="0" cellspacing="0" width="590">
<%
sql="select * from [information] where id="&request("id")&""
set rs=Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,3,3
%>
<tr>
<td colspan="3"><img name="index_7_r1_c1" src="images/spxx.jpg" width="590" height="49" border="0" alt=""></td>
</tr>
<tr>
<td colspan="3"><img name="index_7_r2_c1" src="images/index_7_r2_c1.jpg" width="590" height="9" border="0" alt=""></td>
</tr>
<tr>
<td width="16" height="643" background="images/index_7_r3_c1.jpg"> </td>
<td width="567" valign="top">
<table width="94%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="161" rowspan="7"><div align="center"><img src="upfile/<%=rs("tupian")%>" width="110" height="130" border="0"></div></td>
<td width="22" height="16"> </td>
<td width="127"><span class="style4">【仪器名称】<%=rs("mingcheng")%></span></td>
<td width="220" ><span class="style4">【仪器简介】<%=rs("jianjie")%></span></td>
</tr>
<tr>
<td height="16"> </td>
<td><span class="style4">【出租价格】<%=rs("shichang")%></span></td>
</tr>
<tr>
<td height="16"> </td>
<td><span class="style4"><a href="lookpro.asp?id=<%=rs("id")%>" target="_blank">【查看信息</a>】</span></td>
<td><span class="style4">【上架日期】<%=rs("riqi")%></span></td>
</tr>
<tr>
<td height="16"> </td>></td>
<td><span class="style4">【仪器编号】<%=rs("xinghao")%></span></td>
</tr>
<tr>
<td height="19"> </td>
<td><span class="style4">【<a href="gouwu.asp?ProdId=<%=rs("id")%>">租借仪器</a>】</span></td>
<td><span class="style4">【仪器等级】
<%if rs("dengji")="2" then response.Write("精品") else response.Write("普通")%>
</span></td>
</tr>
<tr>
<td height="16"> </td>
<td><span class="style4">【浏览次数】<%=rs("cishu")%></span></td>
<td><span class="style4">【仪器数量】<%=rs("shuliang")%></span></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30"> </td>
</tr>
</table>
<table width="96%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="31%"><span class="style2">仪器介绍:</span></td>
<td width="69%"> </td>
</tr>
<tr>
<td> </td>
<td><%=HTMLEncode(rs("shuoming"))%></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30"> </td>
</tr>
</table>
<table width="96%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="31%"><span class="style2">仪器备注:</span></td>
<td width="69%"> </td>
</tr>
<tr>
<td> </td>
<td><%=HTMLEncode(rs("beizhu"))%></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30"> </td>
</tr>
</table>
<table width="96%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><span class="style2">用户评论:</span> <a href="lookcomment.asp?id=<%=rs("id")%>" target="_blank">查看用户评论</a></td>
</tr>
<tr>
<td>
</td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30"> </td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="172">
<form action="lookpro.asp" method="post">
<div align="center">
<textarea name="comment" cols="60" rows="12"></textarea>
<input type="hidden" name="id" value="<%=rs("id")%>">
<input type="submit" value="评论">
<input type="hidden" name="action" value="add">
<input type="hidden" name="mingcheng" value="<%=rs("mingcheng")%>">
</div>
</form> </td>
</tr>
</table></td>
<td width="7" background="images/index_7_r3_c3.jpg"> </td>
</tr>
<tr>
<td height="7" colspan="3"><img name="index_7_r4_c1" src="images/index_7_r4_c1.jpg" width="590" height="7" border="0" alt=""></td>
</tr>
<%
rs("cishu")=rs("cishu")+1
rs.update
rs.close
set rs=nothing
%>
</table></td>
<td width="8"><img name="index_r2_c3" src="images/index_r2_c3.jpg" width="5" height="753" border="0" alt=""></td>
</tr>
<tr>
<td colspan="3"><!--#include file="foot.asp" --></td>
</tr>
</table>