O'Reilly logo

PHP and MySQL for Dynamic Web Sites: Visual Quickpro Guide, Second Edition by Larry Ullman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Writing the Configuration Scripts

This Web site will make use of two configuration-type scripts. One, config.inc.php, will manage errors and could be used for other purposes, such as defining functions and establishing constants. The other, mysql_connect.php, will store all of the database-related information.

Making a configuration file

The sole purpose of the configuration file will be to establish the error-management policy for the site. The technique involved—creating your own error handling function—was covered in Chapter 6, “Error Handling and Debugging.” In this chapter I’ll modify the original version in a couple of ways.

During the development stages, I’ll want every error reported in the most detailed way (Figure 13.3). Along with ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required