Basic HTML version of Foils prepared May 3 1998

Foil 50 Dynamic HTML Forms - I

From Java Blend and Cold Fusion High Level Database Interfaces CPS616 Web Technologies -- Spring 98. by Chao Wei Ou


1 A dynamic form is an HTML form generated by a cfm file that uses elements created with database query results and CFML.
2 This example shows a select list of employees' names that is created with a query against the employees table.
3 <CFQUERY NAME="EmpName" DATASOURCE="CF 3.0 Examples">
4 SELECT Employee_ID, LastName, FirstName
5 FROM Employees
6 </CFQUERY>
7 <FORM ACTION="example.cfm" METHOD="post">
8 <SELECT NAME="Employee_ID">
9 <CFOUTPUT QUERY="EmpName">
10 <OPTION VALUE="#Employee_ID#">#LastName#, #FirstName#
11 </CFOUTPUT>
12 </SELECT>
13 <INPUT TYPE="submit" VALUE="Submit">
14 </FORM>

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sat Nov 28 1998