MACROMEDIA COLDFUSION MX 61-GETTING STARTED BUILDING COLDFUSION MX Getting Started page 83

Building coldfusion mx applications
Table of Contents

Advertisement

The following page shows the expected result:
Reviewing the code
The following table describes the ColdFusion code used to build the Trip Detail page:
Code
<cfquery name="TripQuery"
dataSource="CompassTravel"
maxRows=1>
<cfif IsDefined("URL.ID")>
WHERE tripID = #URL.ID#
</cfif>
Explanation
The
tag includes a
cfquery
limits the number of result rows brought back from the
database. In the Trip Detail page, we want to only show a
single row at a time, therefore,
The URL.ID specifies a parameter that can be contained
within the URL that requests this page. If the ID parameter
is passed within the URL, it is used in the SQL query to
identify the tripID to SELECT. You can use the CFML
function
to determine if a parameter is passed
IsDefined
within the URL. It can also be used to determine if the user
has entered data in form fields prior to the form post action.
Enhancing the Trip Maintenance application
attribute. This attribute
maxRows
is set to 1.
maxRows
83

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the COLDFUSION MX 61-GETTING STARTED BUILDING COLDFUSION MX and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Coldfusion mx

Table of Contents