Adding new customers
An application that adds new customers is essentially the same as an insert record application, with one additional
function. If you??™ve ever tried to get a username on America Online that even remotely resembles your
own name, chances are you??™ve encountered the function I??™m talking about??”just ask bobsmith01234x. For a
username to be useful, it must be unique; therefore, the Web application must check a submitted username
for uniqueness. Dreamweaver??™s Check New Username server behavior does just this.
Before you can apply the Check New Username server behavior, however, you must create a page with the
proper form elements for all the data necessary. Moreover, you need a Dreamweaver Insert Record server
behavior (refer to Figure 23-15 earlier in this chapter). As the name implies, the Insert Record server behavior
creates a new record and adds it to the specified data source.
The one difference between a standard Insert Record server behavior and the one used in this circumstance
is that you leave the destination page field (After Inserting, Go To) blank. Leaving this field empty enables
the Check New Username server behavior to control the redirection.
The Check New Username server behavior verifies that the requested username is not already in the data
source and redirects the user if it is.
Pages:
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321