Form for collecting information:
<html><head><title>Forms to XML</title></head> <body><h1>Address Collector</h1> <form action="formhtml.asp" method="POST"> <p>First Name:<input type="text" name="firstname" size="20" /></p> <p>Last Name:<input type="text" name="lastname" size="30" /></p> <p>Address 1:<input type="text" name="address1" size="40" /></p> <p>Address 2:<input type="text" name="address2" size="40" /></p> <p>City:<input type="text" name="city" size="25" /> State/Province:<input type="text" name="state" size="25" /></p> <p>ZIP/Postal Code:<input type="text" name="postalcode" size="15" /> Country:<input type="text" name="country" size="25" /></p> <p><input type="submit" name="Submit" /></p> </form> </body></html>
ASP Script for returning it as HTML:
<%@LANGUAGE="JavaScript"%> <html><head> <title><%=Request.Form.item("firstname")%> <%=Request.Form.item("lastname")%></title> </head> <body> <p>First Name: <%=Request.Form.item("firstname")%></p> <p>Last Name: <%=Request.Form.item("lastname")%></p> <p>Address: <%=Request.Form.item("address1")%><br> <%=Request.Form.item("address2")%></p> <p>City: <%=Request.Form.item("city")%></p> <p>State: <%=Request.Form.item("state")%></p> <p>Postalcode: <%=Request.Form.item("postalcode")%></p> <P>Country: <%=Request.Form.item("country")%></p> </body></html>
Copyright 2000 Simon St.Laurent