<!--#Include FILE="WapConfig/WapHeader.asp"-->
<%
Dim FreeWordId : FreeWordId=Request("FreeWordId")
If FreeWordId<>"" Then 
	Session("FreeWordId")=FreeWordId
Else 
	FreeWordId=Session("FreeWordId")
End If
If Request("ToDo")="ToAdd" Then  
	Receive_A=Request("Send_A") 'XML.DelSpecialMark(
	Receive_B=Request("Send_B")
	Receive_C=XML.DelSpecialMark(Request("Send_C")) '内容
	Receive_D=XML.DelSpecialMark(Request("Send_D"))
	If Receive_A="" Then
			ErrorMessage=XML.Ascii("请输入姓名。")
		ElseIf Receive_B="" Then
			ErrorMessage=XML.Ascii("请输入主题。") '如果没有错误，则错误信息为空
		ElseIf Receive_C="" Then
			ErrorMessage=XML.Ascii("请输入内容。") '如果没有错误，则错误信息为空
		Else
			ErrorMessage="" '如果没有错误，则错误信息为空
	End If	
If ErrorMessage="" Then
	XML.StrSql="Insert Into FreeWordReply (FreeWordId,PersonName,Title,Content,IP,PhoneNumber) Values (" & FreeWordId & ",'" & Receive_A & "','" & Receive_B & "','" & Receive_C & "','" & XML.PhoneIP & "','" & XML.PhoneNumber & "')"		
	XML.RedirectPath=XML.WapPath & "Success.asp?ToDo=AddFreeWordReplyOk"	
	XML.MdbInsert
End If
End If
'以下为文件正文。
'显示标题
XML.WriteOut "<h2>发表评论</h2>"
XML.WriteOut "<ul><li>"
If Request("WhatToDo")="YouAreFirst" Then XML.WriteRow "您好，目前此文还没有评论。<br/>欢迎您对本文看法，与其他人一起来分享本文，并和今后来到这里的朋友们交流。<br/>+++++++++++++"
If ErrorMessage<>"" Then XML.WriteRow ErrorMessage
XML.WriteOut "<form method='post' action='" & XML.ThisFileName & "'>"
XML.WriteOut "<h3>姓名:</h3>"
XML.WriteOut "<input type='text' name='Send_A' value=''/>"
XML.WriteOut "<h3>主题:</h3>"
XML.WriteOut "<input type='text' name='Send_B' value=''/>"
XML.WriteOut "<h3>内容:</h3>"
XML.WriteOut "<input type='text' name='Send_C' value=''/>"
XML.WriteRow "<input type='hidden' name='ToDo' value='ToAdd'/>"
XML.WriteOut "<input type='submit' value='提交'/>"
XML.WriteOut "</form>"
XML.WriteOut "</li></ul>"
'以下为返回链接等
XML.WriteOut XML.Div(,,"N")
XML.WriteRow XML.ImgA("","FreeWord_ReplyList.asp","查看本文评论")
XML.WriteRow XML.ImgA("","FreeWord_ReplyTopList.asp","查看最新评论")
XML.WriteRow XML.ImgA("","index.asp","返回上级")
%>
<!--#Include FILE="WapConfig/WapFooter.asp"-->
 
