<!--#include file="conn.asp"-->
<!-- #include file="../inc.asp" -->
<!-- #include file="../ydzq1.asp" -->
<%call Head() %>
<%Call saycarda("发表评论")
%>



<%dim ids,pin,id,pa,cid,TP
ids=trim(request.QueryString("class"))
id=trim(request.QueryString("id"))
cid=Trim(request.QueryString("cid"))
TP=trim(request.QueryString("TP"))
if TP<>"" then TP=clng(TP)
pin=request("pin")
if pin="" then

  Call Error("评论内容不能为空！")
  end if

if len(pin)>300 then

  Call Error("评论字数不能大于300字！")
  end if

id=trim(request("id"))

if id="" or IsNumeric(id)=False then
  Call Error("ID无效！")
  end if

pa=request.QueryString("pa")
if pa="" or IsNumeric(pa)=False then pa=1


ip=Request.ServerVariables("REMOTE_ADDR")


'更新评论

set rs=Server.CreateObject("ADODB.Recordset")
rs.open"select * from yfpin",connqiu,1,2

rs.addnew
rs("fileid")=id
rs("pin")=pin
rs("uid")=myid
rs("ip")=myni
rs("pltime")=now()
rs.update
rs.close
set rs=Nothing

connqiu.Execute("update zhuqiu set yfpin=yfpin+1 Where id="&id)


conn.close
set conn=nothing
%>
评论成功！！<br/>
<a href='yfpinlist.asp?id=<%=id%>&amp;class=<%=ids%>&amp;cid=<%=cid%>&amp;pa=<%=pa%>&amp;TP=<%=TP%>&amp;saytk=<%=saytk%>&amp;sid=<%=sid%>'>查看评论</a><br/>


<%
response.write "-----------------<br/><a href='/saytkcom/lmzhuqiu/index.asp?saytk="&saytk&"&amp;sid="&sid&"'>返回足球赛事</a><br/>-----------------"
call headsay()%>