<!--#Include FILE="WapConfig/WapHeader.asp"-->
<%
'以下为文件正文，利用ASP函数的部分。
'显示标题
XML.WriteOut "<h2>签写留言</h2>"
XML.WriteOut "<ul><li>"
If Request("ToDo")="ToAdd" Then  
	Receive_A=Request("Send_A") '
	Receive_B=Request("Send_B")
	Receive_C=XML.DelSpecialMark(Request("Send_C")) '主题
	Receive_D=XML.DelSpecialMark(Request("Send_D")) '内容
	If Receive_C="" Then
			ErrorMessage=XML.Ascii("请输入主题。")
		ElseIf Receive_D="" Then
			ErrorMessage=XML.Ascii("请输入内容。") '如果没有错误，则错误信息为空
		Else
			ErrorMessage="" '如果没有错误，则错误信息为空
	End If	
If ErrorMessage="" Then
	If Receive_A="" Then GuestType=1 Else GuestType=0
	XML.StrSql="Insert Into SQ_GuestBook(GuestID,TopicID,GuestName,GuestSex,GuestTitle,GuestContent,GuestImages,GuestFace,GuestIP,GuestIsPassed,GuestContentLength,GuestDatetime) Values ('" & ---- & "','" & --- & "','" & Receive_A & "','" & Receive_B & "','" & Receive_C & "','" & Receive_D & "','01','1','" & XML.PhoneIP & "'," & True & ",'" & Len(Receive_D) & "',#" & Now & "#)" 
	XML.WriteOut XML.StrSql	
	XML.RedirectPath=""'XML.WapPath & "Success.asp?ToDo=AddGuestBookOk"
	XML.MdbInsert
End If
End If
'以下为文件正文。
If ErrorMessage<>"" Then XML.WriteRow ErrorMessage
XML.WriteOut "<form method='post' action='" & XML.ThisFileName & "'>"
If Session("OnLineName")="" Or Session("OnLineName")="游客" Then 
XML.WriteOut "<h3>姓名:</h3>"
XML.WriteRow "<input type='text' name='Send_A' value=''/>"
XML.WriteOut "性别:"
XML.WriteOut "<select name='Send_B' size='1'>"
XML.WriteOut "<option value='0'>先生</option>"
XML.WriteOut "<option value='1'>小姐</option>"
XML.WriteRow "</select>"
End If
XML.WriteOut "<h3>主题:</h3>"
XML.WriteOut "<input type='text' name='Send_C' value=''/>"
XML.WriteOut "<h3>内容:</h3>"
XML.WriteOut "<input type='text' name='Send_D' 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("","GuestBook.asp","返回上级")
%>
<!--#Include FILE="WapConfig/WapFooter.asp"--> 