Welcome to WebmasterWorld Guest from

Forum Moderators: travelin cat

Message Too Old, No Replies

PHP / Sql on a mac



9:08 am on Sep 7, 2005 (gmt 0)

10+ Year Member

Any advice on setting up PHP and a test server on osx 10.39?

I'm pretty much an adept at Mac stuff but when it comes to this I'm having real issues getting scripts etc to work on my local (inbuilt) apache server.

Any chance someone could detail a blow by blow account to specifically set up a php test server using dreamweaver and my OS (specifically mac)?

I want to test stuff like switching stylesheets etc with PHP includes.



9:26 am on Sep 7, 2005 (gmt 0)

10+ Year Member

You'll find an excellent, step by step tutorial on installing MySQL and PHP on MAc OS X from SitePoint - very helpful indeed.


9:35 am on Sep 7, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

Apple has some quick info about MySQL on MacOSX:

They recommend using Marc Liyanage's upgrade at entropy.ch or the official binary installer from MySQL (both linked from apple's info page). It's pretty easy if you are new to mysql / php. Apple also recommends tools like phpMyAdmin and other helpfull stuff ...


9:53 am on Sep 7, 2005 (gmt 0)

10+ Year Member


I wil check this out - although I was rather hoping someone would spell it out on this thread - I know people have got better things to do, but if I am having trouble I'm sure other Mac users are having trouble working with the apache server, php and sql in Mac osx 10.3.

Great to hear from other mac users!

(PS - found a great C64 simulator for the mac yesterday called Power64 which alongside a game called Thrust (available at c64.com) really does bring back the memories!)

Maybe I'll write a blow by blow account!


7:12 pm on Sep 7, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

Macromedia provides directions that discuss using Dreamweaver with Apache/MySQL/PHP:

[macromedia.com ]

Also, are you aware you can get this out-of-the-box with Mac OS X Server? It isn't cheap but it makes it easy to get started.


8:10 pm on Sep 7, 2005 (gmt 0)

10+ Year Member

MAMP gives you Apache, MySQL and PHP in a nice, self-contained, free and non-commercial package :

It's easier to work with than the native server.

There is also XAMPP, which appears to provide more
but is "still in the first steps of development. Use at you own risk!"


1:17 pm on Sep 8, 2005 (gmt 0)

10+ Year Member

This MAMP stuff looks excellent - anybody think of any reason I shouldnt use this?


5:07 pm on Sep 9, 2005 (gmt 0)

10+ Year Member

anybody think of any reason I shouldnt use this?

I should add MAMP is what I use myself, at least when using OS X. It's very much a "click-here-to-install" kind of thing and easy to install and also remove.


12:16 am on Sep 10, 2005 (gmt 0)

10+ Year Member

ummm... apache and PHP come pre-installed on OS X.

There are official installer packages for MySQL.

And to update PHP, use an installer package from entropy.ch

And turn apache on by enabled Web sharing in your system prefs.

Doesn't get any easier than that.


8:18 am on Sep 12, 2005 (gmt 0)

10+ Year Member

I think I'm going to have a nervous breakdown....I think I might have screwed up with apache.

When I use mamp the mysql server turns on but the apache does not.

I turn on web sharing and (I think) I used to get a url where my web folder was. I dont get this now.

I know it seems simple but I just cant seem to get it up and running.

What should I be able to do to check if apache is running my server (and when I say server I mean basically to run a test server, on the computer I work on, to test my web sites.

Do I need to reinstall apache or am I just a w@nker?

I want to simply use php but I dont even know this is what apache is used for....


3:54 am on Oct 13, 2005 (gmt 0)

5+ Year Member

<I want to simply use php but I dont even know this is what apache is used for.... >

OK< Apache is the webserver, PHP is preprocessor for web page and MySQL is a database that PHP can talk to.


1) Download the latest PHP compiled package from entropy.ch. It is a simple package installer - double click to install.
2) Turn on Web Sharing in System Preferences.
3) In Safari, simply type "localhost' into the address bar and hit return.

If the Webserver (apache) is running, you'll see something (not sure what, depending on if there's anything in there, but it shouldn't be a 'Failure to connect, or couldn't find server' message!)

Now, in your HTML editor of choice (can I recommend BBEdit?) in a new page, type:




and save this file as "index.php" in:


Then, back to Safari... type 'localhost/index.php' into the address bar.

If you get a huge page detailing every aspect of your PHP installation, you're good to go!

If not, come back and let us know!


2:29 pm on Oct 14, 2005 (gmt 0)

10+ Year Member

OK - I got it up and running. Cheers everyone.


1:14 am on Nov 17, 2005 (gmt 0)

10+ Year Member

ALL that I can say is that I am in EXACTLY the same boat.

I was given a site to work on that was developed by a college student as a senior technology demonstration project. It was competely written in php with some flash/xml and mysql involved. In credible techology.

And dog buttugly...

I need to set up a test server on my Mac (running 10.4.2) just so that I can see the heck is going on (I use Dreamweaver mx)

I will follow the excellent suggestions here and report back-- I promise!


3:47 am on Nov 17, 2005 (gmt 0)

5+ Year Member

trust me, I come from a pure graphic design background. Follow the instructions in my earlier post, and visit the Entropy forums if you get stuck - its easy!

Now, as foe learning PHP/My SQL, along with Flash/Actionscript/XML, well, 's a whole new topic....

Will help where I can... no guarantees, tho!


10:27 am on Nov 17, 2005 (gmt 0)

10+ Year Member

Yes - Listen to the advice here. Forget everything you've done so far - get the entropy download and you should be up and running - I'm on Tiger now as well.

Happy php'ing!


9:08 pm on Nov 20, 2005 (gmt 0)

5+ Year Member

MySQL does not work in Tiger specially the default install from apple. There is no fix so far or at least I haven't been able to find one or somebody that had it working.


9:48 pm on Nov 21, 2005 (gmt 0)

Featured Threads

Hot Threads This Week

Hot Threads This Month