Setting up a PHP/MySQL testing server on your own computer is an invaluable time saver for web developers. Once set up and functioning properly, you can develop, test, and prep your dynamic sites without having to upload to your live server every time you make a change. Mac OS X comes with an Apache server and PHP installed by default, but they lack a great deal of the useful tools you will be using and they require you to be comfortable using Terminal which many new developers can find cumbersome.
This tutorial shows you how to get around using Terminal and easily set up your Mac to run a PHP/MySQL testing environment that you can use for testing PHP pages. If you are a Windows user and want to set up a testing server view the tutorial for Installing XAMPP on Windows.
In most cases, having a local testing server will save you time and make developing your dynamic website easier. However, depending on the extent to which a customer is developing websites, this may not be necessary.
...you are not creating/modifying PHP pages.
...you are using a WebAssist Solution Pack and have no intention of customizing the code or functionality.
In this case, you should upload the Solution Pack directly to your server after modifying the necessary configuration files.
...you are using a product that creates PHP pages but you don't need to test until you upload to your live server.
...you are using eCart, DataAssist, or SecurityAssist to create a dynamic application. This will significantly speed up your development process.
IMPORTANT! Apache comes standard on many Mac computers, and will definitely be running if you've ever ever enabled (or attempted to enable) a testing server on your Mac using the default Apache server. Even if you didn't turn it on, let's make sure it's off to avoid conflicts.
MAMP installs everything you need to run PHP pages and a MySQL database on your local machine.
Once installed, you can use the MAMP Control Panel to start your testing server.
To ensure the testing server works on the default port (80), you should change the port numbers used.
With your testing server now installed and running, there are a few final steps you should take to make sure everything is configured to work perfectly.
You should now see a confirmation window informing you that 'MAMP is installed on your Mac and everything is working!' This interface allows you to configure certain MAMP settings
You should test your PHP Installation to make sure everything is set up for you to load PHP pages on your local computer.
This page displays the login credentials for your MySQL database. The username (SuperUser), 'root' is created for you automatically and is the username you can use for accessing your MySQL database or creating a database connection.
If you see a PHP page similar to this, you have completed setting up your PHP/MySQL testing server.
Now that your testing server is completely set up, you can preview PHP pages on your local computer. The location on your computer to place your files by default is /Applications/MAMP/htdocs. You can change this in the Apache tab in the MAMP Control Panel Preferences.
Now, you should define a site in Dreamweaver that references your testing server.
Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.
These out-of-the-box solutions provide you proven, tested applications that can be up and running now. Build a store, a gallery, or a web-based email solution.