OSX 10.8.2 localhost directory & MySql / PHPMyAdmin

You know, just because it will bug me again at some point:

If for any reason you don’t want to use the “sites” folder for your web development, you can head to

and upload code directly into your http://localhost folder.

to install PHPMyAdmin, just plop that PHPMyAdmin folder just downloaded right into the above folder.

To Install MySQL however, follow these steps:

Download the .dmg MySQL installed from MySQL.com

Run the first installed, then the auto-start installer, and finally the Preference Pane add-on.

Run this code in terminal:

and then load /etc/php.ini and replace any instance of

with

Start the MySQL server using the preference pane add-on, then run the following in Terminal:

Replacing PASSWORD with a password of your choice.

The last thing to do is head to the PHPMyAdmin directory, and copy the config.sample.inc.php to config.inc.php and edit that file, replacing the

RANDOM BLOWFISH CHARACTERS part with random characters!

Finally, head to http://localhost/phpmyadmin and your good to go!