⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 prod_detail.asp

📁 网上购物系统
💻 ASP
字号:
<%
dim url
url=request.ServerVariables("Server_NAME")&request.ServerVariables("SCRIPT_NAME") 
if(len(trim(request.ServerVariables("QUERY_STRING")))>0) then 
  url=url & "?" & request.ServerVariables("QUERY_STRING") 
end if 
%>
<!--#include file=Conn.asp -->
<!--#include file=include/MyRequest.asp -->
<!--#include file=Sub.asp -->
<%
dim id
id=my_request("id",1)
if id="" or isnull(id) or IsNumeric(id)=False then
  response.write("<script>alert(""参数错误!"");location.href=""index.asp"";</script>")
  response.end
end if

//更新商品浏览次数
sql="update prod_info set prod_info_hitnums=prod_info_hitnums+1 where id="&id
conn.execute (sql)

dim prod_info_name,prod_info_AdWord,cid,prod_info_PicB,prod_info_flag,prod_info_PriceM,prod_info_PriceS,prod_info_detail
Set rs= Server.CreateObject("ADODB.Recordset")
sql="select prod_info_name,prod_info_AdWord,cid,prod_info_PicB,prod_info_flag,prod_info_PriceM,prod_info_PriceS,prod_info_detail,prod_info_no from prod_info where id="&id
rs.open sql,conn,1,1
prod_info_name   = rs(0)
prod_info_AdWord = rs(1)
cid                 = rs(2)
prod_info_PicB   = rs(3)
prod_info_flag   = rs(4)
prod_info_PriceM = rs(5)
prod_info_PriceS = rs(6)
prod_info_detail = rs(7)
prod_info_no = rs(8)
rs.close
set rs=nothing

txt=""
if instr(prod_info_flag,1) then txt="推荐、"
if instr(prod_info_flag,2) then txt=txt&"新品、"
if instr(prod_info_flag,3) then txt=txt&"特价"
  
//调出商品类别名称
dim prod_class_name
sql="select prod_class_name from prod_Class where cid="&cid
set rs=conn.execute (sql)
prod_class_name=rs(0)
rs.close
set rs=nothing

Set rs=Server.CreateObject("ADODB.Recordset")
sql="select root_info_QQ,root_info_QQOnOff,root_info_WangWang,root_info_WangWangOnOff from root_info where id=1"
rs.open sql,conn,1,1
root_info_QQ            =rs(0)
root_info_QQOnOff       =rs(1)
root_info_WangWang      =rs(2)
root_info_WangWangOnOff =rs(3)
rs.close
set rs=nothing
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">	
<head>
<title><%=prod_info_name%></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>

<body>
<!--#include file="top.asp" -->
<!--#include file="left.asp" -->
<SCRIPT language="JavaScript" src="js/URLEncode.js"></SCRIPT>
<SCRIPT language="JavaScript" src="js/PicFit.js"></SCRIPT>
<%
response.write "<table width=100% border=0><tr><td><a href=index.asp>首页</a> &raquo; <a href=prod_ListCategory.asp?cid="&cid&">"&prod_class_name&"</a> &raquo; 商品介绍</td></tr></table>"
response.write "<table width=100% border=0><tr>"
response.write "	<td colspan=3><h2 align=center>"&prod_info_name&"&nbsp;&nbsp;<font color=FF0000>"&prod_info_AdWord&"</font></h2></td>"
response.write "</tr>"
response.write "<tr>"
response.write "	<td valign=top align=center width='50%'>"
response.write "    	<a href=uploadpic/"&prod_info_PicB&" style='cursor:hand' onclick='OpenFullSizeWindow(ShowImage.src);return false'><img name=ShowImage src=uploadpic/"&prod_info_PicB&" onload=fitSize();><br><span id=ShowImgText></span>放大查看</a>"
response.write "	</td>"
response.write "	<td valign=top width='35%'>"
response.write "		<table border=0 width=100% cellpadding=4 style=border-collapse: collapse>"
response.write "			<tr><td>商品货号: "&prod_info_no&"</td></tr>"
response.write "			<tr><td>所属类别: "&prod_class_name&"</td></tr>"
response.write "			<tr><td>商品特性: "&txt&"</td></tr>"
response.write "			<tr><td>市 场 价: <font color=#808080>¥"&FormatNumber(prod_info_PriceM,2,-1)&"</font></td></tr>"
response.write "			<tr><td>本 站 价: <font color=#FF6600 size=5> <b>¥"&FormatNumber(prod_info_PriceS,2,-1)&"</b></font></td></tr>"
response.write "			<tr><td style=border-bottom: 1px solid #E8E8E8><a href=Cart_Add.asp?id="&id&"><img src=images/add_shop_cart.gif></a></td></tr>"
		              		Set rs=Server.CreateObject("ADODB.Recordset")
		              		sql="select root_option_OnOffAliPayButton from root_option where id=1"
		              		rs.open sql,conn,1,1
                      		root_option_OnOffAliPayButton=rs(0)
                      		rs.close
                      		set rs=nothing
                      		if root_option_OnOffAliPayButton=1 then
response.write "    		<tr><td><a href=OnlyOne_ByAlipay.asp?flag=1&url="&url&"&prod_info_PriceS="&prod_info_PriceS&"&prod_info_name="&prod_info_name&" target=_blank><img src=images/zhifubao.gif width=100></a></td></tr>"
							end if
response.write "		</table>"
response.write "	</td>"
response.write "	<td valign=top width='15%'>"
						if (root_info_QQOnOff=0 and root_info_QQ<>"") or (root_info_WangWangOnOff=0 and root_info_WangWang<>"") then
response.write "		<table width=100% cellspacing=1 cellpadding=4 class=MainTable><tbody class=table_td>"
							if root_info_QQOnOff=0 and root_info_QQ<>"" then
response.write "    		<tr><td class=MainHead>QQ咨询:</td></tr>"
								qq=split(root_info_QQ,",")
                            	for k=0 to ubound(qq)  
response.write "    				<tr><td><a target=_blank href=http://wpa.qq.com/msgrd?V=1&Uin="&trim(qq(k))&"&Site=购物咨询&Menu=yes><img src=http://wpa.qq.com/pa?p=1:"&trim(qq(k))&":16 alt=QQ咨询></a></td></tr>"
								next
							end if
							if root_info_WangWangOnOff=0 and root_info_WangWang<>"" then
response.write "			<tr>"
response.write "				<td>淘宝旺旺:<br>"
%>								<script language="javascript">
						        var taobaoid;
						        var taobaos;
                                taobaos="<%=root_info_WangWang%>";
                                taobaoid=URLEncode(taobaos)
                                document.writeln("<a target=_blank href=http://amos1.taobao.com/msg.ww?v=2&s=1&uid="+taobaoid+">")
						        document.writeln("<img border=0 alt=点击这里给我发消息 src=http://amos1.taobao.com/online.ww?v=2&s=1&uid="+taobaoid+">")
						        document.writeln("</a>")
						    	</script>
<%response.write "				</td>"
response.write "			</tr>"
							end if
response.write "		</tbody></table>"
						end if
response.write "	</td>"
response.write "</tr>"
response.write "<tr><td colspan=3 class=RightHead>商品详细描述</td></tr>"
response.write "<tr><td colspan=3 style=table-layout:fixed;word-break:break-all class=maintxt>"&prod_info_detail&"</td></tr></table>"
%>
<!--#include file="end.asp" -->
</body>
</html>
<SCRIPT language="JavaScript" src="js/URLEncode.js"></SCRIPT>
<SCRIPT language="JavaScript" src="js/PicFit.js"></SCRIPT>

⌨️ 快捷键说明

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