<!---
Name:        insert1.cfm
Author:      Ben Forta (ben@forta.com)
Description: Table row insertion demo
Created:     4/20/01
--->

<!--- Get ratings --->
<CFQUERY DATASOURCE="ows" NAME="ratings">
SELECT RatingID, Rating
FROM FilmsRatings
ORDER BY RatingID
</CFQUERY>

<!--- Page header --->
<CFINCLUDE TEMPLATE="header.cfm">

<!--- New movie form --->
<CFFORM ACTION="insert2.cfm">

<TABLE ALIGN="center" BGCOLOR="orange">
    <TR>
        <TH COLSPAN="2">
            <FONT SIZE="+1">Add a Movie</FONT>
        </TH>
    </TR>
    <TR>
        <TD>
            Movie:
        </TD>
        <TD>
            <CFINPUT TYPE="Text"
                     NAME="MovieTitle"
                     MESSAGE="MOVIE TITLE is required!"
                     REQUIRED="Yes"
                     SIZE="50"
                     MAXLENGTH="100">
        </TD>
    </TR>
    <TR>
        <TD>
            Tag line:
        </TD>
        <TD>
            <CFINPUT TYPE="Text"
                     NAME="PitchText"
                     MESSAGE="TAG LINE is required!"
                     REQUIRED="Yes"
                     SIZE="50"
                     MAXLENGTH="100">
        </TD>
    </TR>
    <TR>
        <TD>
            Rating:
        </TD>
        <TD>
            <!--- Ratings list --->
            <SELECT NAME="RatingID">
                <CFOUTPUT QUERY="ratings">
                    <OPTION VALUE="#RatingID#">#Rating#</OPTION>
                </CFOUTPUT>
            </SELECT>
        </TD>
    </TR>
    <TR>
        <TD>
            Summary:
        </TD>
        <TD>
            <TEXTAREA NAME="summary"
                      COLS="40"
                      ROWS="5"
                      WRAP="virtual"></TEXTAREA>
        </TD>
    </TR>
    <TR>
        <TD>
            Budget:
        </TD>
        <TD>
            <CFINPUT TYPE="Text"
                     NAME="AmountBudgeted"
                     MESSAGE="BUDGET must be a valid numeric amount!"
                     VALIDATE="integer"
                     REQUIRED="NO"
                     SIZE="10"
                     MAXLENGTH="10">
        </TD>
    </TR>
    <TR>
        <TD>
            Release Date:
        </TD>
        <TD>
            <CFINPUT TYPE="Text"
                     NAME="DateInTheaters"
                     MESSAGE="RELEASE DATE must be a valid date!"
                     VALIDATE="date"
                     REQUIRED="NO"
                     SIZE="10"
                     MAXLENGTH="10">
        </TD>
    </TR>
    <TR>
        <TD>
            Image File:
        </TD>
        <TD>
            <CFINPUT TYPE="Text"
                     NAME="ImageName"
                     REQUIRED="NO"
                     SIZE="20"
                     MAXLENGTH="50">
        </TD>
    </TR>
    <TR>
        <TD COLSPAN="2" ALIGN="center">
            <INPUT TYPE="submit" VALUE="Insert">
        </TD>
   </TR>
</TABLE>

</CFFORM>

<!--- Page footer --->
<CFINCLUDE TEMPLATE="footer.cfm">

