<!--- This example shows the use of CFINPUT to validate input --->
<HTML>

<HEAD>
<TITLE>
CFINPUT Example
</TITLE>
</HEAD>

<BASEFONT FACE="Arial, Helvetica" SIZE=2>
<BODY  bgcolor="#FFFFD5">

<H3>CFINPUT Example</H3>

<!--- this example shows the use of CFINPUT within a CFFORM to
ensure simple validation of text items --->
<CFFORM ACTION="cfinput.cfm" METHOD="POST" ENABLECAB="Yes">

<!--- phone number validation --->
Phone Number Validation (enter a properly formatted phone number):
<BR><CFINPUT TYPE="Text" NAME="MyPhone" MESSAGE="Please enter telephone number, formatted xxx-xxx-xxxx (e.g. 617-761-2000)" VALIDATE="telephone" REQUIRED="Yes"><font size=-1 color=red>Required</FONT>
<!--- zip code validation --->
<P>Zip Code Validation (enter a properly formatted zip code):
<BR><CFINPUT TYPE="Text" NAME="MyZip" MESSAGE="Please enter zip code, formatted xxxxx or xxxxx-xxxx" VALIDATE="zipcode" REQUIRED="Yes"><font size=-1 color=red>Required</FONT>
<!--- range validation --->
<P>Range Validation (enter an integer from 1 to 5):
<BR><CFINPUT TYPE="Text" NAME="MyRange" RANGE="1,5" MESSAGE="You must enter an integer from 1 to 5" VALIDATE="integer" REQUIRED="No">
<!--- date validation --->
<P>Date Validation (enter a properly formatted date):
<BR><CFINPUT TYPE="Text" NAME="MyDate" MESSAGE="Please enter a correctly formatted date (dd/mm/yy)" VALIDATE="date" REQUIRED="No">

<INPUT TYPE="Submit" NAME="" VALUE="send my information">

</CFFORM>


</BODY>

</HTML>       
