ONLINEPROOFINGSITE.COM

beretta proof marks - www.onlineproofingsite.com

Menu


The following information (which we won't get into in this chapter) must be collected in order to associate a credit card with a particular


employee: Field Name Date Type Key CreditCardID AutoNumber PK EmployeeID Number FK Type Text N/A Number Text N/A Expiration Date/Time N/A   And finally, the Departments table, which represents a specific department in which employees can work, resembles the following: Field Name Date Type Key DepartmentID AutoNumber PK Department Text N/A   Now that you've reviewed the structure of the tables we'll cover in this chapter, let's begin creating the New User Registration form to accommodate the data collection. NOTE Remember, most of the steps we'll perform in the next few sections can be performed using any server model. When nuances appear across technologies, I will point them out. The only server model that warrants its own section is ASP.NET. From the middle of this chapter and moving forward, I'll cover all of the same examples presented in the first half of the chapter using ASP.NET.   Creating the New User Registration Form Most applications, if not all, simulate the fields within a database with HTML form objects. Because form objects allow the user to interact with the web application, they are the perfect channel for collecting information and subsequently inserting that information into the database. Before you can begin creating the New User Registration form however, you must first create a table to serve as the primary means for structuring the form objects in a cohesive and usable fashion. Begin creating the table by following these steps: 1. Begin creating the New User Registration form by creating a new page from a template. From the File menu, select New, navigate to the Templates tab, and select the template named Template from the site you're working with. 2. Place your cursor in the editable region titled Content, remove the text that exists in the region, and insert a new form by selecting Insert, Form, Form. 3. Let's add our table. First, decide how many rows your table will contain. A quick count of all the necessary fields in the Employees table reveals that you need about 10 rows. However, you may want to include a few more to account for a header, a spacer, and a button element. A safer number would be 14. Knowing that, select Insert, Table. The Insert Table dialog appears. In the dialog, create a table that has 14 rows, 2 columns, a width of 450 pixels, and 0 border, cell padding, and cell spacing. Click OK to insert the new table within the form on the page. 4. Add all appropriate content for personal information including billing/shipping information, and so on to the table. You can merge cells along the way to create the header. The result is shown in Figure 26.1. Figure 26.1. Add all appropriate content to the new table. [View full size image]   TIP You can format the table and content in the table as you see fit. Feel free to create styles so that your table and the content within it becomes more attractive.