大家帮忙看看,怎么解决!
<!--#include file="conn.asp"-->
<!--#include file="inc/const.asp"-->
<!--#include file="LJR_pet_conn.asp"-->
<!--#include file="inc/plus_check.asp"-->
<html>
<body>
<%
Response.Buffer = True
Response.ExpiresAbsolute = Now() - 1
Response.Expires = 0
Response.CacheControl = "no-cache"
call checkpost()
dim chentitle,action,temp,itemid
chentitle="[雪宠宠物冒险乐园v1.0]·特殊专卖店"
Dv_plus.name="LJRpet"
'Dv_plus.checklogin()
Dvbbs.LoadTemplates("")
Dvbbs.Stats="[雪宠宠物冒险乐园v1.0]·特殊专卖店"
Dvbbs.Nav()
Dvbbs.Head_var 0,"","[雪宠宠物冒险乐园v1.0]·宠物大厅","LJR_pet_index.asp"
if DvBBS.UserId = 0 then
AlarmErrmsg
else
call petdb("")
call petonline(chentitle)
Dim Rs,SQL
dim itemlx
Dim zblvxz,zblvxzs,DEF_PET_szmoney,DEF_PET_skillmoney,DEF_PET_allstonemoney
Dim DEF_PET_lifeupmoney,DEF_PET_powerupmoney,DEF_PET_defupmoney,DEF_PET_pkNPCxzmoney,DEF_PET_pkNPCxzNum
Dim DEF_PET_seeLogmoney,DEF_PET_dbexpmoney,DEF_PET_dbexpNum,DEF_PET_AutoPKnpcmoney,DEF_PET_AutoPKnpcNum
Dim mylink,payuser
mylink=mylink&"http://"&request.ServerVariables("Server_NAME")&request.ServerVariables("SCRIPT_NAME")
if(len(trim(request.ServerVariables("QUERY_STRING")))>0) then
mylink=mylink & "?" & request.ServerVariables("QUERY_STRING")
end if
'response.Write mylink
payuser=request("payuser")
Dim curdate,v_oid,text,v_md5info,userID
'根据系统时间产生订单,格式:YYYYMMDD-v_mid-HMMSS
userID=dvbbs.UserSession.documentElement.selectSingleNode("userinfo/@userid").text
curdate=now()
v_oid=year(curdate)&month(curdate)&day(curdate)&"-"&v_mid&"-"&hour(curdate)&minute(curdate)&second(curdate)
text = userID&v_oid
'提醒您:下面是初始设置
zblvxzs=45 '装备等级限制最低
zblvxz=55 '装备等级限制最高
DEF_PET_szmoney = 2 '素质归元之石价格
DEF_PET_skillmoney = 2 '技能归元之石价格
DEF_PET_allstonemoney = 3 '重生药水价格
DEF_PET_lifeupmoney = 5 '长春圣水价格
DEF_PET_powerupmoney = 5 '力量圣水价格
DEF_PET_defupmoney = 5 '体质圣水价格
DEF_PET_pkNPCxzmoney = 1 '怪兽诱捕卡价格
DEF_PET_pkNPCxzNum = 2000 '怪兽诱捕卡数量 实际减半,即2000=1000
DEF_PET_seeLogmoney = 1 '查看记录通行证价格
DEF_PET_dbexpmoney = 5 '双倍经验卡价格
DEF_PET_dbexpNum = 1000 '双倍经验卡使用后打怪生效数量限制
DEF_PET_AutoPKnpcmoney = 10 '自动打怪
DEF_PET_AutoPKnpcNum = 1000 '自动打怪使用后打怪生效数量限制
%>
<!-- #include file="LJR_pet_menu.asp" -->
<%
call main()
end if '不是DVBBS用户结束
sub main()
action = Checkstr(request("action"))
if action = "" or isNULL(action) then
action = "weaponbox"
end if
select case action
case "weaponbox"
call weaponbox()
case "buyweapon"
itemid=lcase(request("itemid"))
if itemid = "" or isNULL(itemid) then
call showmessage("抱歉,系统找不到此数据!!!","?")
end if
call buyweapon()
case "itembox" call itbox()
case "buyitem"
call buyitem()
case "stone"
call godstone()
case else
call showmessage("抱歉,系统找不到此数据!!!","?")
end select
end sub
sub buyitem()
Response.Write("</table></table>")
dim temp,itemlx,sql,sql2,itmoney,logitt
Dim LJRpet_lifeupXZ,LJRpet_powerupXZ,LJRpet_defupXZ,LJRpet_lifeup,LJRpet_powerup,LJRpet_defup
' 0 1 2 3 4 5
Set rs=connpet.ExeCute("select LJRpet_lifeupXZ,LJRpet_powerupXZ,LJRpet_defupXZ,LJRpet_lifeup,LJRpet_powerup,LJRpet_defup FROM [LJRpet_useritem] WHERE username='"&dvbbs.membername&"'")
LJRpet_lifeupXZ = rs(0)
LJRpet_powerupXZ = rs(1)
LJRpet_defupXZ = rs(2)
LJRpet_lifeup = rs(3)
LJRpet_powerup = rs(4)
LJRpet_defup = rs(5)
itemlx=request("item") '类型
select case itemlx
case "exp"
itmoney=DEF_PET_basicexpmoney
logitt="经验药水"
case "exp2"
itmoney=DEF_PET_basicexpmoney2
logitt="经验圣水"
case "szstone"
itmoney=DEF_PET_szmoney
logitt="素质归元之石"
case "skillstone"
itmoney=DEF_PET_skillmoney
logitt="技能归元之石"
case "allstone"
itmoney=DEF_PET_allstonemoney
logitt="重生药水"
case "LJRpet_lifeup"
If LJRpet_lifeup>=1 Then call showmessage("请您先将之前买的先使用!","LJR_pet_itbox.asp?action=stone")
If LJRpet_lifeupXZ>5 Then call showmessage("您已经超过使用次数!","?action=stone")
If LJRpet_lifeupXZ<1 Then
itmoney=DEF_PET_lifeupmoney
Else
itmoney=DEF_PET_lifeupmoney*LJRpet_lifeupXZ*2
End if
logitt=""&LJRpet_lifeupXZ&"级长春圣水"
case "LJRpet_powerup"
If LJRpet_powerup>=1 Then call showmessage("请您先将之前买的先使用!","LJR_pet_itbox.asp?action=stone")
If LJRpet_powerupXZ>5 Then call showmessage("您已经超过使用次数!","?action=stone")
If LJRpet_powerupXZ<1 Then
itmoney=DEF_PET_powerupmoney
Else
itmoney=DEF_PET_powerupmoney*LJRpet_powerupXZ*2
End if
logitt=""&LJRpet_powerupXZ&"级力量圣水"
case "LJRpet_defup"
If LJRpet_defup>=1 Then call showmessage("请您先将之前买的先使用!","LJR_pet_itbox.asp?action=stone")
If LJRpet_defupXZ>5 Then call showmessage("您已经超过使用次数!","?action=stone")
If LJRpet_defupXZ<1 Then
itmoney=DEF_PET_defupmoney
Else
itmoney=DEF_PET_defupmoney*LJRpet_defupXZ*2
End if
logitt=""&LJRpet_defupXZ&"级体质圣水"
Case "LJRpet_pkNPCxz"
itmoney=DEF_PET_pkNPCxzmoney
logitt="怪兽诱捕卡"
case "LJRpet_seelog"
itmoney=DEF_PET_seeLogmoney
logitt="记录通行证"
case "LJRpet_dbexp"
itmoney=DEF_PET_dbexpmoney
logitt="双倍经验卡"
case "LJRpet_AutoPKnpc"
itmoney=DEF_PET_AutoPKnpcmoney
logitt="自动打怪卡,并获赠双倍经验卡"
case else
call showmessage("抱歉,系统找不到此数据!!!","?")
end select
If itemlx = "LJRpet_AutoPKnpc" Then '提醒您:这是买【自动打怪卡】,送【双倍经验卡】
sql2= "update [LJRpet_useritem] set LJRpet_AutoPKnpc=LJRpet_AutoPKnpc+1,LJRpet_dbexp=LJRpet_dbexp+1 where username='"&DvBBS.MemberName&"'"
else
sql2= "update [LJRpet_useritem] set "&itemlx&"="&itemlx&"+1 where username='"&DvBBS.MemberName&"'"
End If
connpet.ExeCute(sql2)
Dim logTSbuy
logTSbuy=""&DvBBS.MemberName&"使用<a href=http://www1.86zjw.cn/cl/ target=_blank>官方帐号</a>:<font color=blue>"&payuser&"</font>花费"&itmoney&"点卷购买了:<font color=red>"&logitt&"</font>!"
Call AddpetLog(logTSbuy,9)
rs.close
Set rs=nothing
connpet.close
set connpet=Nothing
'call showmessage("你已成功购买"&LJRpet_defup&"!","?action=stone")
Response.redirect "?"
end sub
接下