<!--#Include File="Connection.Asp"-->
 
<%
Dim JaZ,C,flyN,B,cur
Set JaZ = new q_zone
B = JaZ.JaKillStr(Request.QueryString("JaUid"))
If B="" Then
B= "2"
End If
C=Split(JaZ.GetHeadElement("*",B,"JaFaceSet",""),"<><><>")
flyN = split(Trim(C(2)),"|")
If Cint(Trim(C(1)))<>0 Then
cur = "CURSOR:url('cur/"&C(1)&".ani');"
Else
cur = ""
End If 
%>

<%
Dim JaCheckIsLog
JaCheckIsLog = JaZ.JaIsRegUser(B)
If JaCheckIsLog <> "no" Then

Dim Jatitle,Japid,P,I
Dim JaInSQL
Dim JaVicNum,albumID
JaVicNum = SESSION("VicNum")
Jatitle = JaZ.JaKillStr(Request.Form("photoRe"))
albumID = JaZ.JaKillStr(Request.QueryString("albumID"))
Japid = JaZ.JaKillStr(Request.Form("photoID"))

If Jatitle="" Then
Response.Write "<script language=javascript>alert('评论不能为空!');"
Response.Write "window.document.location.href='javascript:history.go(-1)';</script>"
Else

JaInSQL = "(JaPhotoID,JaUid,JaReUser,JaContent) Values("&Japid&",'"&JaVicNum&"','"&SESSION("LoginUserName")&"','"&Jatitle&"')"
JaZ.JaInsert "JaPhotoRe",JaInSQL

Response.Write "<script language=javascript>alert('添加成功!');"
Response.Write "window.document.location.href='AlbumMenu.asp?JaUid="&B&"&albumID="&albumID&"';</script>"

End if
Else
Response.Write "<script language=javascript>alert('请登录以后再评论!');"
Response.Write "window.document.location.href='javascript:history.go(-1)';</script>"
End if
%>
