Accessibility
 

Building your first dynamic website – Part 3: Building the administrative back end


Table of Contents

Comments

Create the admin page

To create the administrative page, you'll start by creating a page containing just a title, and build around it the protection mechanism to allow access only by authorized users.

The first thing you have to do is to create the admin page.

  1. Launch Dreamweaver if you haven't done so already.
  2. If you see the Welcome screen shown in Figure 1, choose PHP from the Create New column.

     Creating a new
PHP page from the Dreamweaver Welcome screen

    Figure 1. Creating a new PHP page from the Dreamweaver Welcome screen

    If you don't see the Welcome screen, choose File > New and in the dialog box that appears choose PHP as the Page Type, leave <none> as the Layout, and click Create (see Figure 2).

    Creating a new
PHP page with the New Document dialog box

    Figure 2. Creating a new PHP page with the New Document dialog box

    A new page, labeled Untitled-1, is created and opened.

Next, follow these steps:

  1. In the Title text box, replace Untitled Document with a more descriptive title, for example, type Administration.
  2. In the new page, add the same text (for example, type Administration again).
  3. Make it a level 1 heading: Select the new text and then click the button labeled "h1" on the Text tab of the Insert toolbar.
  4. Press the Right Arrow key to clear the selection and press the Enter key to create a new paragraph.
  5. To save the page choose File > Save. For the name, type admin. Select PHP Files for the Save As Type option.

    Note: If you were working in a ColdFusion or ASP development environment, you would create a new ColdFusion or ASP VBScript file. These files would be saved as ColdFusion Templates and Active Server Pages, respectively.

  6. Preview the page using Live view or by opening it in your browser of choice (choose File > Preview in Browser).