The Edit Companies page is for modifying a company record in the database . The actual update action and form will be generated automatically through the use of the Update Record Form Wizard.
Building the update page will consist of the following steps:
While creating the update page, you will notice and take advantage of a new feature in MX Kollection 3: UI persistence. This means that you only have to configure some fields once, and the Dreamweaver interfaces will remember it. The next time you attempt to use a wizard, it will be already configured the way you did it last time. If you have disabled the UI persistence, you will have to go through all steps of the wizards.
As mentioned when creating the company insert page, the page design used is kept pretty basic, as it is not the goal of this tutorial. For the update's page design, you should repeat the same steps used for the insert page, only replacing the text with "Modify company data".
The Update Record Form Wizard has 2 or 3 steps, depending if you have MX Form Validation installed. For this section, you can ignore the validation since it will not be used. If you have installed the MX Kollection 3 bundle, then MX Form Validation is installed too, and you will have the third step in the wizard.
This part of the tutorial will take full advantage of the user interface persistence provided by MX Kollection 3. As you open the Update Record Form Wizard, you will notice that this time the Connection, Table, Primary key column and even the After updating, go to text box are automatically selected with the values used in the Insert Record Form Wizard.
Note: It is assumed that you followed this tutorial in order and have already applied and configured the Insert Record Form Wizard.
Configuring the Update Record Form Wizard can be considered from the start completed, but let's still browse through the two steps to see if all is fine. If you are in a hurry, you can just hit the Finish button. The update operation will work nonetheless.
The first step, containing the connection and table information, now has two new fields: the Primary key equals drop-down menu and text field. This is where you decide which way will the company's unique identifier be passed. By default, the wizard considered that the method will be URL Parameter, and its name is id_com. Leave the default values.
The user interface looks as follows:

Click on the Next > button if you want to continue checking the dialog box, or Finish to apply the wizard.
The second step of the wizard also has all options filled by the user interface persistence. There are no new fields on this dialog box, so after taking a look, you can directly click on Finish.
The already filled dialog box looks like:

At this point, the update page is completed and can be previewed in the browser. No record will be available for update however, until a URL parameter is passed to the page.
To send the correct URL parameter to this page, the best way involves
on clicking the Update link in
the companies list folder (/company/index.php):

The wizard adds an HTML form, an Update Record server behavior and a transaction recordset . This recordset will contain upon page initialization data retrieved from the company table, related only with the company to update. You can use this recordset to ease understanding of which company is being edited, by adding the company's name to the title. To do so, you must follow the next steps:


The next topic of the tutorial will teach you how to implement the company delete page.