Creating a Form to Edit Existing Data

Constructing the edit form will draw on two principles you've learned in the last two days. First, it will query the "calls" table, looking for contents in the ID field that match the numeric variable passed to it from admin_edit.cfm. Second, it will create a standard Web form, inserting the values from the specified record into the entry boxes for editing.

To better understand this, let's work backwards and take a look at a completed version of the page we want to create. It appears in Figure 7.12.

Figure 7.12. The completed page admin_edit.cfm.

Figure 7.12 shows what you'll see when you click on a call's ...

Get Sams Teach Yourself ColdFusion® in 21 Days now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.