
923
DEVELOPING
COLDFUSION 9 APPLICATIONS
Working with Documents, Charts, and Reports
Las
t
upda
te
d 8/5/2010
<h3>Employee Information</h3>
<cfoutput>
<table>
<tr>
<td>Name:</td>
<td>#fields.txtfirstname# #fields.txtlastname#</td>
</tr>
<tr>
<td>Department:</td>
<td>#fields.txtdeptname#</td>
</tr>
<tr>
<td>E-Mail:</td>
<td>#fields.txtemail#</td>
<tr>
<td>Phone:</td>
<td>#fields.txtphonenum#</td>
</tr>
<table>
</cfoutput>
Application examples that use PDF forms
The following examples show how you can use PDF forms in your applications.
PDF submission example
The following example shows how to populate fields in a PDF form created in LiveCycle Designer based on an
employee login information. When the employee completes the form and clicks the PDF Submit button, the entire
PDF form with the data is submitted to a second processing page where ColdFusion writes the completed form to a file.
On the ColdFusion login page, an employee enters a user name and password:
<!--- The following code creates a simple form for entering a user name and password.
The code does not include password verification. --->
<h3>Timesheet Login Form</h3>
<p>Please enter your user name and password.</p>
<cfform name="loginform" action="loginform_proc.cfm" method="post">
<table>
<tr>
<td>user name:</td>
<td><cfinput type="text" name="username" required="yes"
message="A user name is required."></td>
</tr>
<tr>
<td>password:</td>
<td><cfinput type="password" name="password" required="yes"
message="A password is required."></td>
</tr>
</table>
<br/>
<cfinput type="submit" name="submit" value="Submit">
</cfform>