| |
starbug0
Posts: 1
Score: 0
Joined: 9/13/2005
Status: offline
|
I'm new to vb scripting. All i'm trying to do is make a simple post form. I've posted my code below. I want to be able to post a persons name, email and message to the same page after the user has filled in the form and clicked on submit. The condition formula: If the form is completed fully then all details will be displayed. Else a message will be displayed saying that a form field/s hasen't been completed. Please help. <form action="contact.asp" method="post"> Name: <input type="text" name="uname" size="20" /> <br> E-mail: <input type="text" name="email" size="20" /> <br> Message: <textarea name="message" cols="50" rows="5"></textarea> <br> <input type="submit" value="Submit" /> <input type="reset" value="Reset" /> <br> </form> <% dim uname dim email dim message uname=Request.Form("uname") email=Request.Form("email") message=Request.Form("message") If name<>"" & email<>"" & message<>"" Then Response.Write("You have not filled all the fields in the form!") Else Response.Write("Name: " & uname & "<br />") Response.Write("E-mail: " & email & "<br />") Response.Write("Message: " & message & "<br />") %> Regards,
_____________________________
Wayne
|
|