Creating the Basic Pages

Before I get into the heart of the Web application (the content management itself), I need to create two more pages. One will be index.php and will act as the home page for the site. The second will be mysql_connect.php, a script that connects to MySQL and selects the database to be used (see the “Database Scheme” sidebar in the next section for more information about the database).

To make the home page

1.
Create a new PHP script in your text editor (Script 12.3).
<?php # Script 12.3 - index.php
Script 12.3. The application’s home page (add meaningful content as needed).

2.
Set the page title and include the HTML ...

Get PHP and MySQL for Dynamic Web Sites: Visual Quickpro Guide, Second Edition 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.