<%
'chosing your colors'
HeadingCellBgColor="#000099"
HeadingCellTextColor="#ffffff"
CellBgColor="#f0f0f0"
CellTextColor="#000000"
%>
STAY N' CHARGE GUESTBOOK
<%
'the data requested and stuff
Flag = Request.form("Flag")
If Flag = 1 then
Name = Request.form("Name")
Email = Request.form("Email")
State = Request.form("State")
Comment = Request.form("Comment")
Comment = server.HTMLencode(Comment) 'Don't allow HTML
Comment = Replace(Comment,VbCrlf," ")
'fun stuff! error validation
errmsg="
"
If Replace(Name," ","") = "" then errmsg = errmsg & "
Name is missing
"
If Replace(Email," ","") = "" then
errmsg = errmsg & "
Email Address Is Missing
"
ElseIf InStr(Email,"@")=0 then
'all emails contain an at sign eg. you@you.com
errmsg = errmsg & "
Email Address Is missing an '@'
"
ElseIf InStr(Email,".")=0 then
'all emails contain a dot eg. you@you.com
errmsg = errmsg & "
Email Address needs to be something like somebody@somwhere.com
"
End If
'URL is not required
If Replace(Comment," ","") = "" then errmsg = errmsg & "