Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > macOS > PHP Included with Mac OS X?

PHP Included with Mac OS X?
Thread Tools
Agent69
Mac Elite
Join Date: Jun 2000
Status: Offline
Reply With Quote
Nov 10, 2003, 11:13 AM
 
According to an article I recently read, PHP is included as an Apache module in Panther. However, I can't seem to find directions for turning it on.

Can anyone point me in the right direction?
Agent69
     
VEGAN
Senior User
Join Date: Jun 2002
Location: UK
Status: Offline
Reply With Quote
Nov 10, 2003, 01:24 PM
 
Originally posted by Agent69:
According to an article I recently read, PHP is included as an Apache module in Panther. However, I can't seem to find directions for turning it on.

Can anyone point me in the right direction?
I know MySQL comes with the Mac X Server... but I didn't know PHP would come... mind citing the article?
     
[APi]TheMan
Mac Elite
Join Date: Sep 2001
Location: Chico, CA and Carlsbad, CA.
Status: Offline
Reply With Quote
Nov 11, 2003, 03:06 AM
 
To turn on PHP you have to edit Apache's config file (you need admin privileges).

Edit the file using your text editor of choice. I'll use pico because it's easier to give instructions and harder to lose a beginner:
sudo pico /etc/httpd/httpd.conf

Then, from pico, type:
Control-W (to activate the search feature), then type php. Move over to the beginning of the line and uncomment the line.
That line should look like this:
Code:
LoadModule php4_module
Then type Control-W again, and then hit enter to search for occurances of "php" again... Keep going until you find the next line that is commented; uncomment that line too... it should read like this after you're done with it:
Code:
AddModule mod_php4.c
Then write the changes by hitting Control-O and hitting enter.

To make Apache look at its config file again type:
sudo apachectl graceful

Done !
"In Nomine Patris, Et Fili, Et Spiritus Sancti"

     
Agent69  (op)
Mac Elite
Join Date: Jun 2000
Status: Offline
Reply With Quote
Nov 11, 2003, 10:22 PM
 
I did what you said and it worked like a charm. I then ran phpinfo() and according to the results, the built in PHP module for Panther includes support for both MySQL and PostgreSQL.

Very nice!


Thanks,
Agent69
     
[APi]TheMan
Mac Elite
Join Date: Sep 2001
Location: Chico, CA and Carlsbad, CA.
Status: Offline
Reply With Quote
Nov 12, 2003, 03:01 PM
 
Originally posted by Agent69:
I did what you said and it worked like a charm. I then ran phpinfo() and according to the results, the built in PHP module for Panther includes support for both MySQL and PostgreSQL.
Sweet. I'm glad my instructions were easy enough to follow, though it sounds like you knew what to do, just needed a little pointing in the right direction.

Glad it's working, man.
"In Nomine Patris, Et Fili, Et Spiritus Sancti"

     
   
Thread Tools
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 12:50 AM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,