Make your own free website on

Connecting MS Access to the Web

This tutorial will use Apache, PHP and Microsoft Access for database connectivity. PHP and Apache are free but covered under an Open Source Agreement. Instructions on how to install these software packages are provided below.

Install Microsoft Access97 or 2000. Make sure all ODBC drivers are installed.

Apache is a powerful web server and PHP is a powerful scripting language. PHP and Apache tied with many available databases enable powerful Internet and e-commerce solutions for businesses today.

Behind the web page:



Installing Apache and PHP

To install Apache and PHP on the Windows platform read the following tutorial:

***** Since we will be using Microsoft Access make sure to enable, "extension=php3_odbc.dll" *****

For General Apache and PHP installation, the following tutorials will help:


Developing the database

Connecting the database to the Web Server


Windows folks ( sorry MAC users) go to : Control Panel -> ODBC Data Sources Select System DSN


Click Add ... Select Database Driver you want. (This case choose Microsoft Access Driver)


Choose configure -> Type easy to remember name in "Data Source Name", give it a description and then click "Select..." to locate your database. You can also do other things, for example, add password, using the "Advanced ..." button, but we do not need that in this case.

Thatís it! Youíre done with database setup.

PHP is the actual link to the database. Make sure that your PHP configuration file enables the ODBC.dll. Read the tutorials above to ensure this is correct.


Developing an Interactive Website

Inserting information into a database



No HTML is written, just a PHP script that handles the data. PHP automatically creates variables to match the text boxes on the previous pages. The names of these variables are derived from the names of the text boxes in the previous HTML form.


Retrieving information from the database



Search Results

We will see the this result page on searchresults.php3