Apache Web-Serving with Mac OS X: Part 3
by Morbus Iff01/04/2002
Editor's note: In the first part of this series, Kevin showed you how to easily start serving Web pages from your Mac OS X computer. In the second article, he explored the world of CGI access. Today, he moves forward with a look at PHP.
Turning on PHP4
We're on the last legs of our trip down Feature Lane, Impressiville. This will be the easiest section of our journey, mainly because we'll be going through the paces based on what we already know. Much like CGI, PHP is very popular and well supported, and very often installed on Web hosts by default. Much like SSI, the code is included and interpreted into the actual HTML of your Web pages.
Just like our other sections on CGI and SSI, turning on PHP involves searching for the feature name ("php") within our Apache configuration file. The first entries we come up against are:
# LoadModule php4_module libexec/httpd/libphp4.so
# AddModule mod_php4.c
These lines are just like those we encountered when we were messing around with CGIs -- they enable or disable the loading of PHP on a restart of our Apache Web server. Since they're commented with that little "#" character, we've got to remove the "#" to enable them. Do that now.
Moving on to our next search result, we see:
# For example, the PHP 3.x module will typically use:
#
# AddType application/x-httpd-php3 .php3
# AddType application/x-httpd-php3-source .phps
#
# And for PHP 4.x, use:
#
# AddType application/x-httpd-php .php
# AddType application/x-httpd-php-source .phps
|
|
We saw these same sorts of lines when we were enabling
SSI. In essence, they're saying that any file with the .php extension should
be processed by the PHP module we just enabled. As we'll see soon enough, Mac OS X (versions 10.1 and above) comes pre-installed with PHP 4, so go ahead and uncomment the two "for
PHP 4.x" lines. Save the Apache configuration file, and stop and start the
Web server using the "Sharing" preference panel.
We're going to return to our Apache error log for a second to illustrate a simple, yet helpful bit of information. Each time you start Apache, it will spit out a single line telling you that everything has started successfully. Often times, it will look like so:
[notice] Apache/1.3.20 (Darwin) configured
-- resuming normal operations
When you add a third party module or feature
(like PHP, mod_perl, mod_ssl, etc.), Apache will graciously make mention of it in its startup line.
If you just restarted the Apache Web server now, take a look at the error
log by typing:
tail /var/log/httpd/error_log
You should see Apache wax poetic with:
[notice] Apache/1.3.20 (Darwin) PHP/4.0.6
configured -- resuming normal operations
Apache tells us
that PHP is enabled, but how do we really know for sure? Rather easily,
actually. Take that index.shtml file that we were testing SSIs with, and
rename it to index.php. Now, replace the contents with the
following:
<html><body>
<h1>Gleefully Served By Mac OS X</h1>
<? phpinfo()?>
</body></html>
Finally, go to
http://127.0.0.1/index.php and you should see a long page full of PHP
diagnostic information. If so, rub your hands with a gleam in your eye,
because PHP has now been added to your arsenal. Want to add a simple Web-based email program for your traveling coworkers? Check out PHPost. Note: Most PHP
applications require a sophisticated database backend, like MySQL or
Postgres -- PHPost is one of the few that doesn't. While installing and
configuring these database systems is relatively easy on Mac OS X, it would be
outside the scope of this primer. Want to see an article on this? Let us know by commenting below.
Choosing Who Sees What
|
| |
It's five in the morning. You've gone through three six packs of soda, two tins of Penguin Reds, and an untold number of delicious snacky treats. You've got a CGI poll script ready to quiz the employees on the menu for the next company picnic, an SSI image gallery that happily sends the marketing department into a drool-dripping feature panic, and a PHP app with which your developers can track and monitor their sloppy code.
Now what?
After all you've done, something rather minor. We've just got to throw a little access control on our spunky new intranet -- we wouldn't want the outside world seeing the insanely great job we've done (we'd rather wait and show them the really cool stuff we're gonna do on our personal time, right? Wink, wink, nudge, nudge).
While Apache can certainly handle authenticated access control, we're only going to touch on the location-based side of it. To do so, we're going to return to a snippet of configuration file that we've messed around with before, back when we were enabling SSIs:
<Directory "/Library/WebServer/Documents">
Options Includes Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>
I mentioned we'd eventually touch on the remaining lines, and now is said
time (although, we're still going to rudely skip AllowOverride). Quite
simply, the "Order allow, deny" and "Allow from all" lines are the magic
that will stop outside visitors from perusing our intranet. Right now, as
these lines stand, our intranet is wide open to the public.
This is what we're going to end up with:
<Directory "/Library/WebServer/Documents">
Options Includes Indexes FollowSymLinks MultiViews
AllowOverride None
Order deny,allow
Deny from all
Allow from gatesmcfaddenco.org
</Directory>
See what we've done here? The first thing we did is flip our "Order" directive. This tells Apache to process all "Deny" rules first, and then all the remaining "Allow" rules. Likewise, our first "Deny" is "from all," meaning no one can come knocking. If we denied everyone, of course, no one would be able to see our Macstrosity (rather phenomic, eh?), so we add an "Allow" rule for our GatesMcFaddenCo domain. We can also allow and deny by IP, like "Allow from 209.204.146". This will allow access to anyone from within the GatesMcFaddenCo network, but no one from without.
Conclusion
Before you know it, it's seven in the morning and time to show off your efforts. You're confident, feigning a yawn of boredom, not sleepiness. As the morning sun glints off the silver of your glorious G4 tower, you smile privately -- as has been typical since time began, doing something amazing on the Mac has been incredibly simple. Your boss is impressed, your coworkers are disbelieving, and you're signing a purchase order for the newest mystery item from MacWorld. Oh, life is good.
Don't think we've exhausted everything Apache and Mac OS X has to offer, though. You still
haven't touched mod_ssl, which allows secure server capabilities, nor have
you fiddled with mod_perl, which can speed up your CGI scripts immensely.
You haven't touched the authentication capabilities of Apache's access
control, or even tweaked Apache's configuration with .htaccess files. And
sadly, if someone types in a bad URL for your intranet, you still get an
ugly and generic 404 page.
Only 7:30? Plenty of time to bust those out before lunch. Good luck!
Morbus Iff is the coauthor of Mac OS X Hacks, author of Spidering Hacks, and the alter ego of the pervasively strange Morbus Iff, creator of disobey.com, which bills itself as "content for the discontented."
Showing messages 1 through 153 of 153.
-
php 5 instructions
2009-12-28 13:55:48 stumpygreg [View]
go to http://foundationphp.com/tutorials/php_leopard.php for instructions that match with apache 2.2 and php 5
-
index.php
2005-06-27 15:00:03 TWizard [View]
It seems that when I go to 127.0.0.1, if my index is index.html.en, it just loads it directly. If my index is index.php.en, it lists the files in my web server's main directory.
I am running Mac OS X 10.4 with Apache 1.3 and PHP 5.
I do not see what could be wrong with my httpd.conf. If any of you want, I could put a copy on my web server's index.html.en and put a link here.
Thanks. -
index.php
2005-06-27 15:00:55 TWizard [View]
Oh, by the way, it loads .php pages perfectly. This is the only problem, so far.
-
so easy - but . . .
2005-02-22 12:55:54 videomike [View]
Like so many others, I've benefitted greatly from this tutorial. Thank you. My problem is so easy I can't find the answer . . .
I want to activate PHP 4. I'm using "sudo pico" in lieu of the assumed BBEdit. (good reason, long story) Once I'm into the Apache config file, and I delete the '#' to un-comment something, how do I save it? I've tried ^X for 'exit' and several other options, plus I've just closed the terminal. When I re-enter, the item is still commented out. -
so easy - but . . .
2008-01-11 09:01:26 ludwig_von_rocht [View]
In pico the command is ^O (not a zero)
-
mac,php and variables
2004-09-01 04:52:53 flashsmurf [View]
I've installed Mac OS 10.3.3 succesfully and enabled the apache server and php thanx to your tutorial. There's one problem. In html as well in flash variables are transmitted to the php file, but php can't find them or doesn't recognize them as variables. Variables made within the php script works.What is going wrong?
Thanks in advance, Koen.
-
PHP HTML parsing problem
2003-06-19 16:57:31 enderws [View]
I've got PHP up and running on my local webserver, but I'm having a problem. Whenever I surf to a .php web page served by my box, it prompts me to save the file rather than parsing it for HTML and displaying the webpage. What's wrong? I already added
AddType Application/x-httpd-php .php .html
to my httpd.conf and restarted the webserver. Why would Apache be sending the .php file as a file to be saved rather than HTML? Is it sending the wrong headers? Any help would be appreciated! -
PHP HTML parsing problem
2003-08-16 16:36:04 anonymous2 [View]
I had the same problem. My problem was that it wasn't saving the file with the php extension. It added rtf to the end. Read this article
http://www.macromedia.com/devnet/mx/dreamweaver/articles/php_macintosh.html
And follow the directions for the TextEdit and after doing the changes make sure you open a new file.
-
My vote for an article!
2003-05-30 16:29:37 anonymous2 [View]
"Note: Most PHP applications require a sophisticated database backend, like MySQL or Postgres -- PHPost is one of the few that doesn't. While installing and configuring these database systems is relatively easy on Mac OS X, it would be outside the scope of this primer. Want to see an article on this? Let us know by commenting below."
This is exactly what I'd like to see -- as I'm interested in running a program called WebCalendar which requires php and such database.
Thanks!
blair.at.greenbelt.org
-
php AND ssi?
2003-03-26 06:01:55 anonymous2 [View]
My SSI's work well if I have a .shtml or a .html page but once I try to add .php to:
Addhandler server-parsed .shtml .html .php
when I go to the page it tries and D-load it like a file. How do I have SSI on .php pages?
Thanks much,
Jason -
php AND ssi?
2003-03-26 06:19:31 Morbus Iff |
[View]
If you're trying to get SSI and PHP working together through one .php file, that's impossible in Apache 1.3. You can either have PHP in .php files, or SSI in .php files - you can't mix and match them.
Ignoring the above, it sounds like .php (which may or may not have been associated with mod_php) is being handled by the SSI part of Apache, and since no MIME-type has been defined for .php, your browser doesn't know what to do with it. You'll want to add .php to:
AddType text/html .shtml
But, remember, you can't use PHP and SSI in the same file. It's one or the other. Apache 2.0 purportedly will allow you to do this by setting up filters, but I've yet to experiment with it. -
php AND ssi?
2003-04-02 03:37:25 anonymous2 [View]
I'm Just starting out with PHP, but it strikes me as logical to use the PHP function include() when wanting to include files.
EG.
<?php include("include_this_file.html"); ?>
(of course the icluded file could also be .php)
Another option is that it appears that you can include .php files into .shtml files, and the PHP gets Parsed correctly.
EG.
<!--#include file="info.php"-->
I've tried it with a sample and works fine, though am unsure of Pro's/Con's within a larger web application.
Hope this helps.
-
PHP Nodice. Failed Opening?
2003-01-30 20:16:46 bucky4d4s [View]
The log sez PHP is running, but when I try to open index.php, I get:
Warning: Failed opening '/Library/WebServer/Documents/index.php' for inclusion (include_path='.:/usr/lib/php') in Unknown on line 0
Whassup?
(on OSX 10.2.3) -
PHP Nodice. Failed Opening?
2003-12-30 07:03:17 anonymous2 [View]
You must set permissions for all directories in path /Library/WebServer/Documents/ to 755
and index.php must have 744 -
PHP Nodice. Failed Opening?
2003-04-16 06:10:40 anonymous2 [View]
Probably the permissions are not right. Setting them to a+r might help.
- Green
-
Apache-PHP
2002-11-23 07:03:35 anonymous2 [View]
I've added the 2 lines AddType that were missing and I tried again but that does still nothing when I put PHP in my HTML
With tail /var/log/httpd/error_log, I see
[notice]Apache ... resuming normal operations
[notice]Accept mutex: flock (Default: flock)
Has anybody an idea? -
Apache-PHP
2002-12-31 06:05:34 khasmir [View]
I added the following lines:
#
# To use PHP4
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
I put them after the section of the server-parsed HTML
works fine for me on v10.2.3
-
Pbs with PHP on OS X.2
2002-11-23 06:08:51 anonymous2 [View]
Can anybody tell me exactly what there is to be done with the Apache config file and after modifying it, because I have put the two missing lines (AddTypa application...), and tried with phpinfo as indicated by the article, but it still doesn't work
Thanks in advance. -
Pbs with PHP on OS X.2
2002-12-31 06:07:03 khasmir [View]
I added the following lines:
#
# To use PHP4
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
I put them after the section of the server-parsed HTML
works fine for me on v10.2.3
-
phpInfo() showing my password
2002-11-14 20:15:13 anonymous2 [View]
I am new to PHP and learning a ton from this site! I love it.
I am wondering why I can see my password in the phpinfo() page. It's listed as the _SERVER["PHP_AUTH_PW"] variable under PHP Variables near the bottom.
I posted the same phpinfo() file on a server I have used in the past and it doesn't show up there.
Thanks -
phpInfo() showing my password
2003-06-05 01:25:19 anonymous2 [View]
That scared me too! But I figured out that it only shows up if your site is secured with Authentication and you have already logged in (which may be happening automatically via transparent KeyChain access or other Password Manager type stuff). I tried relaunching my browser and didn't log in to the secured section of my site (the top level of the site is public, but my personal ~user pages are protected), and then ran a file that had phpinfo() in it and the PHP_AUTH_USER and PHP_AUTH_PW variables don't show up in the listing. The PHP module apparenlty has access to your authentication info (I guess that's a good thing?), and that phpinfo page is just showing off _everything_ it knows about. But still it seems like it shouldn't be displaying that by in a general info page - that should be some kind of special command or option, not the default.
-
MySQL or Postgres Please
2002-11-04 11:51:25 anonymous2 [View]
I would appreciate such information
-
PHPost...
2002-11-03 08:40:43 anonymous2 [View]
Yes please !
-
Automatic PHP tasks
2002-10-28 13:44:25 anonymous2 [View]
I'm thrilled about my newly acquired PHP & MySQL knowledge. Thank you O'Reilly and OSX!
I currently include PHP in HTML Web pages, but I'm wondering if there's a way to create PHP tasks that run automatically at intervals (every hour or day), or at startup (run constantly in the background)? Any help or articles about this in relation to OSX would be greatly appreciated.
Thanks. -
Automatic PHP tasks
2002-10-28 16:50:45 anonymous2 [View]
I found a simple solution. Add a scheduled task to your /etc/crontab file and use the curl command to excute any PHP script on your site. Example:
0 0 * * * * curl http://www.yoursite.com/yourscript.php
... then execute this in the terminal:
crontab crontab
For more info about crontab, see "Learning the Mac OS X Terminal: Part 1" <http://www.macdevcenter.com/pub/a/mac/2001/12/14/terminal_one.html>
-
Automatic PHP tasks
2002-10-28 17:00:00 anonymous2 [View]
The crontab line should show a correct permission:
0 0 * * * root curl http://www.yoursite.com/yourscript.php
-
i'm missing some lines in my httpd.conf
2002-10-27 21:45:27 anonymous2 [View]
These lines aren't here:
# For example, the PHP 3.x module will typically use:
#
# AddType application/x-httpd-php3 .php3
# AddType application/x-httpd-php3-source .phps
#
# And for PHP 4.x, use:
#
# AddType application/x-httpd-php .php
# AddType application/x-httpd-php-source .phps
I assume since they are missing, that is why the index.php shows the html coding instead of what it's supposed to.
I'm running OSX 10.2.1 -
SOLUTION for OSX 10.2.x users (the missing lines)
2002-12-10 16:07:08 tronje [View]
I'm running 10.2.2
Just take a look at the lines below then you can easily find the position where you can add the missing lines.
...
<IfModule mod_negotiation.c>
LanguagePriority en da nl et fr de el it ja kr no pl pt pt-br ru ltz ca es sv tw
</IfModule>
# And for php4.x, use:
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
# AddType allows you to tweak mime.types without actually editing it, or to
# make certain files to be certain types.
#
AddType application/x-tar .tgz
...
btw, if you want your browser to detect index.PHP just as it does index.html add the missing parts as shown below.
...
#
# DirectoryIndex: Name of the file or files to use as a pre-written HTML
# directory index. Separate multiple entries with spaces.
#
<IfModule mod_dir.c>
DirectoryIndex index.html index.php index.shtml
</IfModule>
...
-
php paths
2002-10-23 07:46:38 anonymous2 [View]
When I use http://127.0.0.1/index.php everything works fine.
When I use file://localhost/Library/WebServer/Documents/index.php I get the "Gleefully..." part, but not the php info.
Is there a way to make file://localhost/Library/WebServer/Documents/index.php work???
Reason: I am developing web pages using Adobe GoLive and when I preview my files GoLive opens the files in Explorer using the file://localhost... path, and so far the php parts have been excluded.
Thanks for the series and any help you may be able to offer.
Craig -
php paths
2003-08-02 21:20:09 anonymous2 [View]
i'm having this exact same problem. when i'm online and go to http://localhost/somefolder/index.php, the files in Documents folder work fine.
if i unplug the ethernet cable and go to http://localhost i get nothing - that makes sense to me. BUT it i go to file://localhost/somefolder/index.php i get nothing - the files in the .php files in the Sites folder do not work.
any guidance would be great!!
thanks,
scott
ringworm@boardermail.com
-
*To anyone running Jaguar*
2002-10-09 13:03:42 anonymous2 [View]
I see some new messages on here regarding problems with Jaguar. Philocon gave a simple fix, and it worked for me when I tried it. In case you missed it, here it is:
When running through the article, you'll notice that the 3rd and 4th line that are commented on in httpd.conf do not exist. What you must do is add this line (I added it at the end with a comment):
AddType application/x-httpd-php .php
Your PHP test page should now work, and no longer shows up as simple text in your browser. -
*To anyone running Jaguar*
2002-10-10 16:06:49 sckz [View]
Please read the post below yours from me. Following the article works great, also for Jaguar. And my test.php looks beautiful.
But there every forum stops. Why do the scripts I use work on my ISP but not on my own server? Is it a server problem or permissions... what?
Can anyone help. The info page is starting to bore me :)
Thanks,
Sckz -
*To anyone running Jaguar*
2003-01-30 00:05:51 anonymous2 [View]
I got the same problem: all permissions at 777 throughout the file hierarchy & running as superuser - working scripts on my ISP running the same apache server refuse absolutely to work on Jaguar: only simple test.cgi etc will run.
-
PHP doesn't work but IS installed
2002-09-30 05:27:17 sckz [View]
First: this is a great site!
I followed the instructions for installing the PHP module. If I try http://127.0.0.1/index.php (like in the article) I see the long configuration file.
Now I tried a simple PHP script that saves a text you type. This script works on the server of my ISP so I think the script is ok. But it doesn't work on my Mac.
I use OS X 10.2.1. After installing - following the article - and trying my script, the error log tells me:
[Mon Sep 30 13:51:33 2002] [notice] Apache/1.3.26 (Darwin) PHP/4.2.3 configured -- resuming normal operations
[Mon Sep 30 13:51:33 2002] [notice] Accept mutex: flock (Default: flock)
[Mon Sep 30 13:59:09 2002] [error] [client 127.0.0.1] Invalid method in request
Is this a file permission problem? I have no idea what to do. Please let me know!
-
PHP is running, but scrambles HTML and shows up in Source-Code???
2002-09-26 09:56:37 anonymous2 [View]
I'm using Jaguar and installed PHP4.2 (according to this tutorial: http://www.entropy.ch/software/macosx/php/).
Everything seemed to be fine, php is working and obviously processing the PHP-Pages, but after the first PHP-Line, HTML becomes scrambled (i.e. it says means, it strips all '=' and '"' and so on). Plus: the PHP-Code is shown in the source code of the page...
What am I doing wrong?
I changed the httpd.conf like indicated in every tutorial and I also have the php.ini-file in the right place. Have to mention, that I installed Apache/PHP on Windoof-Systems already and that worked pretty fine...
Thanks for any help
Regards
Urs -
PHP is running, but scrambles HTML and shows up in Source-Code???
2002-10-01 17:53:39 philocon [View]
Hi
You write: "I changed the httpd.conf file like indicated in every tutorial." I cannot understand this. You cannot work through the article and make every change shown there because there are a few lines missing in Jaguar. Have you added them? Or is there another problem?
Please let me know
philocon
-
Re: PHP and Apache on Jacuar (OSX 10.2)
2002-09-22 13:25:16 anonymous2 [View]
Thank You!!!
The AddType solved my problem - once I remembered to do a Shift-Refresh.
-
Tomcat + Apache
2002-09-22 10:13:13 anonymous2 [View]
Please tell more about canfiguring Apache to use with Tomcat..
-
Apache + php + jaguar = no go?
2002-09-18 06:24:34 anonymous2 [View]
I did all that this article suggests to get php
working but I just get an error message with every php-file I try. It looks like this on the page:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
And in the Apache logs it looks like this:
[Wed Sep 18 15:13:57 2002] [error] (8)Exec format error: exec of /Library/WebServer/CGI-Executables/test.php failed
[Wed Sep 18 15:13:57 2002] [error] [client 1.1.1.1] Premature end of script headers: /Library/WebServer/CGI-Executables/test.php
Please help. I want to install SquirrelMail which is php-based. Already got sendmail and imap running.
/John
-
Apache + php + jaguar = no go?
2002-09-26 05:51:14 philocon [View]
I solved the problem by adding the line
AddType application/x-httpd-php .php
at the end of httpf.conf
Good luck! -
Apache + php + jaguar = no go?
2002-09-26 05:56:30 philocon [View]
Sorry for the spelling error in my first reply:
httpd[!].conf
-
PHPost Permissions fix
2002-09-13 12:28:50 rymes60 [View]
Another post recommended changing the permissions on the PHPost directories to 777. This allows everyone to read, write, and execute all of the files. I may be wrong, but that is a security concern.
Either way, the Readme file for PHPost recommends the following:
If you are running PHP in safe mode, the directory will have to be chgroup'd to the same group that your web server runs as (usually 'nobody'). You will also want to change the permissions to "drwxrwx---" (that's 770).
changing the group to nobody didn't seem to work for me, so I changed the owner to www (AFAIK the same owner as Apache.). Then I changed the Permissions to 770 (only owner and group can read, write.) and everything works fine. Great little program.
Tom
-
PHP and Apache on Jacuar (OSX 10.2)
2002-09-12 07:55:48 anonymous2 [View]
Couldn't find this anywhere in my httpd.conf file:
# For example, the PHP 3.x module will typically use:
#
# AddType application/x-httpd-php3 .php3
# AddType application/x-httpd-php3-source .phps
#
# And for PHP 4.x, use:
#
# AddType application/x-httpd-php .php
# AddType application/x-httpd-php-source .phps
So just typed in (without single quotes!)
'AddType application/x-httpd-php .php'
after
'AddType application/x-tar .tgz'
uncommented the loadModule and AddModule stuff , restarted Apache and everything worked fine. -
PHP and Apache on Jacuar (OSX 10.2)
2002-12-31 06:08:04 khasmir [View]
I added the following lines:
#
# To use PHP4
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
I put them after the section of the server-parsed HTML
works fine for me on v10.2.3
-
HELP!!! Installed PHP now can't start Apache!
2002-09-11 09:09:08 sat150 [View]
I installed the php module from entropy.ch, and I might have typed something incorrectly at the terminal.
Since the installation I cannot start Apache. When I type 'apachectl graceful' I get the following error:
/usr/sbin/apachectl graceful: httpd not running, trying to start
Syntax error on line 816 of /etc/httpd/httpd.conf:
Invalid command '.phps', perhaps mis-spelled or defined by a module not
included in the server configuration
I opened the file, and line 816 just says 'phps', and it is uncommented (no hash).
Any help would be much appreciated.
-
RE: Where is my error???
2002-09-02 15:42:28 insomnis [View]
I had the same problem as Arellano. Fortunately the problem was a head-slapper. Select your index.php file, do a "show info" on it go to "Name & Extension" and uncheck "Hide extension". Renaming the file in the Finder had given the file the name index.php.shtml. Delete the last ".shtml" part, and the PHP should show up fine.
[sw]
-
Where is my error???
2002-08-12 14:23:00 arellano [View]
Ok, this article was great, unfortunately it doesnt work for me yet. Ok, here is the problem. I edited the httpd file and when i check the error_log (like the article suggests) I see:
[Mon Aug 12 01:51:20 2002] [notice] Apache/1.3.22 (Darwin) PHP/4.0.6 configured -- resuming normal operations
[Mon Aug 12 01:51:20 2002] [notice] Accept mutex: flock (Default: flock)
I have also saved a file test.php in my sites folder with the same code the article suggested.
Now when I go to view test.php at http://127.0.0.1/~username/test.php
I only see "Gleefully Served by Mac OSx" and no printout of php diagnostics.
what could i have done wrong? it says that php4 is enabled... i can see the page, but the php doesnt seem to be working.
please help>
:)
-
Where is my error???
2002-08-12 14:18:35 arellano [View]
Ok, this article was great, unfortunately it doesnt work for me yet. Ok, here is the problem. I edited the httpd file and when i check the error_log (like the article suggests) I see:
[Mon Aug 12 01:51:20 2002] [notice] Apache/1.3.22 (Darwin) PHP/4.0.6 configured -- resuming normal operations
[Mon Aug 12 01:51:20 2002] [notice] Accept mutex: flock (Default: flock)
I have also saved a file test.php in my sites folder with the same code the article suggested.
Now when I go to view test.php at http://127.0.0.1/~username/test.php
I only see "Gleefully Served by Mac OSx" and no printout of php diagnostics.
what could i have done wrong? it says that php4 is enabled... i can see the page, but the php doesnt seem to be working.
please help>
:)
-
Paste in LoadModule/AddModuleLines
2002-08-04 16:43:56 bobmoore [View]
Paste LoadModule/AddModule lines into the httpd.conf file if you can't find the lines. (I finally got it to work by doing so.) -
Paste in LoadModule/AddModuleLines
2002-09-15 15:29:15 timbrooke [View]
hi there - these lines are missing form form my script - I read somewhere the the order of the modules in the script is important ? - so where do i paste these lines in..?
-
edit PHP default settings
2002-07-19 20:57:23 cyndical [View]
First, this is a great series of articles. I can't believe that in the course of one day I've gone from 0 to getting a <?php phpinfo() ?> to work on my Mac!
Anyway, I want to change the 2M file size limit to, say 10, for starters. I can't get the script I have to upload a small gif file, so there's probably some other bit that has to be enabled/path names set.
I can't figure out how to find and edit the right file(s). I can find them in Terminal, but not outside of it.
Pointers? Suggestions? Please!
Thx
-
Permission problems
2002-07-05 06:19:35 morteniv [View]
Thank you for trying to help me out with the webserver in OS X 10.1. When I connect to my server trough a browser I get the index.html file fine (the whole site is at root level in the /library/webserver/documents). But when I hit one of my links to another index.html file I do not have permission to see file. This is the message:
You don't have permission to access /Blaasti/index.html on this server. I have changed the httpd.conf file to deny all and allow localhost (my IP).
What am I doing wrong?
Best regards,
morten -
Permission problems
2002-12-06 16:25:17 anonymous2 [View]
u might want to click on the folder containing the files, press apple-I to view its permissions, and there allow read permission to everyone...then click
on apply to all containing folders and file...
permission is probably just set for the index file as of now ..and not for all the containing files and folders
shak
-
I don't have an index.php file
2002-05-11 13:17:50 mknauf [View]
I even searched the whole drive for "index.php" no joy... should I worry / how can I tell it's really working? -
I don't have an index.php file
2002-08-12 14:25:30 arellano [View]
you should make an index.php file. just cut and paste the sample code they gave in the article and save the file as index.php. hope this helps.
:)
-
problem with Volumes
2002-05-07 01:38:35 wilseven [View]
Hi -
your articles are really great. Are they all in a book somewhere yet? a webserving for OS X book on the way?
Anyway - I wanted to maybe move my document root to another volume, but I have this problem with OS X where it's saying there are a bunch of volumes at /Volumes, even though they've been disconnected. This unfortunately includes even my local volume, which currently reads "Mercury 1" because one of the junk volumes has the name "Mercury". So it seems like it's not refreshing the volume info correctly, which would be a problem when I assign doc root on a volume and os x decides to mount it with a new name...
Any help? I looked around for a LONG time before posting...
Michael
mt@motiontek.com
-
Missing LoadModule/AddModule Lines
2002-04-09 15:52:10 d_simmons [View]
Apple just issued a security upgrade which includes PHP v4.1.2. As with other posters, I didn't have the Load/Add Module lines in my httpd.conf file. After pasting them at the end of the other lines, I restarted Apache, and PHP started with it. whee.
This article has been extremely useful. I'm a University student doing a senior project which requires Apache/PHP/MySQL and is to be served from a RedHat machine to Windows clients. I'll be doing most of the development and testing on my Grape iMac running OS X, and I'm going to use it as an internet server so my project teammates can ftp to it and test from their homes.
The author might want to update part 3 of this article, to let folks know that some installs are missing those two lines, and that they need to insert them themselves. It might save someone from having to forage through these posts.
Thanks again for the much needed info.
Now, off to a team meeting, to get another dig in on my WinTel compadres. Bweh heh heh.
-
Missing LoadModule/AddModule Lines
2002-04-16 17:14:10 Morbus Iff |
[View]
>Now, off to a team meeting, to get another dig
>in on my WinTel compadres. Bweh heh heh.
Exactly! :)
-
Help!!! Error in the httpd file
2002-04-07 23:37:29 plastic1 [View]
I keep getting this error: Syntax error on line 37 of /private/etc/httpd/httpd_macosxserver.conf:
Invalid command 'LoadModule', perhaps mis-spelled or defined by a module not included in the server configuration
Any Ideas on how solve this... I think I've corrupted the config files of apache trying to upgrade to apache 2.*. I have a mac os x server but when I tryed to install php4lib it broke all... I need your help, and also a good way to make work php, apache and mysql on my mac! -
Help!!! Error in the httpd file
2002-04-16 17:09:01 Morbus Iff |
[View]
There have been reports of PHP having problems compiling with 2.0 on OS X - I'm not going to be getting into 2.0 discussions until Apple releases something official on their end (which hopefully will be with a 10.2 release, but if they don't, it won't surprise me).
Generically speaking, a LoadModule error means either a) you're missing a matching AddModule line or b) the module in question is broken. If you had problems building PHP, then there's a good chance that the module on line 37 is the PHP module. Commenting it (by placing a # in front of that line) should give you (at the very least) a different error message.
As for MySQL, there are instructions on how to install it on OS X in part five of this series.
-
PostgreSQL
2002-03-30 10:57:47 Michael Brewer | [View]
I would like to see an article on setting up Postgres on OS X. -
PostgreSQL
2002-06-11 11:01:06 wbug [View]
ditto!!
-
Should this work on osX 10.1.3 ?
2002-03-27 03:19:55 sba [View]
Sorry this should be sitting at the bottom of the 4 th article!
I suppose it all fits in whith the Trilogy thing !
Ie not what is should be!
sba!
-
Should this work on osX 10.1.3 ?
2002-03-26 16:56:33 sba [View]
Hi I've been trying to set up .htaccess on a standard osX 10.1.3 machine I've gone thru the article and I think I've got all the right files in the right places but it still lets me in to any site / Subsite I build!
I did a search on .htaccess on apples site and came accross this and was wondering does it have any relavence?
http://www.apple.com/support/security/security_updates.html
Thanks in advance
Steve
-
Allow from....
2002-03-22 03:38:26 redleader [View]
Hi,
I want to set allow from to a batch of IP numbers, namely:
any 90.0.0.*
any 127.0.0.*
I read the apache manual and tried;
Allow from 90.0 but it did not work and also it did not mention multiple IP range allows. -
Allow from....
2002-03-22 09:02:04 Morbus Iff |
[View]
Allow from 90.0 should have definitely worked for you - when you were denied, did you check your error_log file to see the matching IP that it was denying? If you're previewing locally, it may have seen you as 127.0 instead.
As for multiple ranges, just replicate the "Allow from" line - you can have as many as you want:
Allow from 90.0.0
Allow from 127.0.0
-
tutorial on MySQL please
2002-03-20 20:57:38 clappazon [View]
You said to comment if you wanted a continuing tutorial on database implementation. Please give us a MySQL setup for the Mac tutorial. This whole series has been exceedingly informative and has broken the wall of ignorance I had built around configuration files and investigating the powers of Mac OS X. I would love to get MySQL up and running.
Thanks! -
tutorial on MySQL please
2002-03-22 08:58:29 Morbus Iff |
[View]
Your wish is my command, see part 5 of this series.
-
index.php empty
2002-03-19 19:16:08 driftkop [View]
Hi,
I found the problem. To test the file, I dragged the index.php file to my browser icon, and thus the server looked for:
file://localhost/Users/koen/Sites/index.php
instead of for:
http://127.0.0.1/~koen/index.php
For the latter, it worked fine.
Thanks for your fast response, and for this great series!
- Koen.
-
index.php empty
2002-03-19 10:52:37 driftkop [View]
Hi,
Although I can see that php is enabled in the httpd.error log, I get an empty screen when I load the index.php file. I have my files in /Users/koen/Sites/ and use my own koen.conf file, so maybe in this case I need to add some more lines in my configuration file?
thanks,
- Koen.
-
index.php empty
2002-03-19 14:15:23 Morbus Iff |
[View]
Nope - PHP, by default, is on for every user, regardless of their configuration. Are you sure you uncommented the "AddType" lines? These lines tell the PHP module that .php files should be interpreted - if they're not there, then the browser would just send the results straight to the window, with no processing.
Check that the AddType's are uncommented, and check that the phpinfo line is correctly in that file. Then, load it in your browser, and if there's still nothing there, do a "view source" and see if there's anything in the HTML.
-
no access through 127.0.0.1
2002-03-15 08:06:42 axel_vogelsang [View]
hello,
First of all thanks for that great series. I have a little problem though. Everything is running and I can access all my Files in my user folder and on the root level through the browser. But as soon as I exchange the "Allow from all" in the httpd.conf with my ip-adress, the access is denied. Please help. Thanks
<Directory "/Library/WebServer/Documents">
Options Indexes FollowSymLinks MultiViews Includes
AllowOverride None
Order deny,allow
Deny from all
Allow from 217.37...
</Directory>
-
no access through 127.0.0.1
2002-03-15 12:22:10 Morbus Iff |
[View]
Couple of notes:
When you add the "Allow" from line, are you using your full IP address, or the example shown above (this is a stupid question, but I just have to make sure)? If you're using the 217.37 with three periods after it, it will fail.
The entry above will *only* work on your root directory (not your user directories0. So, when you access your root directory and get denied, check your error_log - there's a good chance that you're actually browsing as 127.0.0.1, and not the 217 address. The error_log will report what IP is being denied.
-
phpost pop connection fails
2002-03-01 19:42:31 dicklacara [View]
phpost installs OK, but login fails in the following code segment in phpost.php.
$sockel has no value after the fsockopen
$errno is 61
$errstr is Connection refused
Code Segment
---------------------
// Open connection
$socket = fsockopen( $h, $p, $errno, $errstr, 15 );
if( ! $socket )
{
$errstr = "Connection refused (" . $prefs["pop"] . ")";
return false;
}
-
PHP.INI
2002-02-27 12:35:21 kuacweb [View]
OK, this is driving us crazy - in order to tell PHP where to route mail created with the mail() tag, you have to specify a SMTP server. Everything I've seen says this can be done in PHP.INI, which is the PHP configuration file. We can't find this file anywhere on our OsX box. It's a standard install. Anyone know where this is supposed to exist under OsX or what it might be called? Thanks! -
PHP.INI
2003-06-29 08:00:18 anole [View]
Well, shoot. Got PHP.INI to be read, and the mail variables set correctly. But now my sent mails from the php-based pMachine... instead of erroring like they did before, they just disappear into the ether. -
PHP.INI
2002-03-02 06:14:16 kkohler [View]
In the FAQ part of this website http://www.entropy.ch/software/macosx/php/ is written, that you have to create the php.ini in order to get mail() worked. For more information go to the website. Greetings Klaus -
PHP.INI - correct path
2002-04-26 18:34:51 lyle [View]
Unfortunetly for me the Entropy site specifies a path (/usr/local/lib/php.ini) that did not work for my system (OSX.1.4) - the path that finaly worked is /usr/lib/php.ini
Take a look at the output of a <?php phpinfo() ?> - item six (Configuration File) specifies where your instilation is looking for the php.ini file. -
PHP.INI
2002-03-04 08:46:45 kuacweb [View]
Thanks! We tried it and it works, however, has anyone noticed a slow response on mail forms? Everything else seems very fast, PHP or not - but the mail forms can take up to 15-20 seconds even for a very simple form. -
PHP.INI
2002-05-30 10:20:56 mdar [View]
Hi I'm just beginning with PHP, can someone tell me how to create a php.ini file either from OS 10.1.4 standard install or from Marc Liyanages
Mo -
PHP.INI
2003-06-03 04:02:12 anonymous2 [View]
Do this:
Make the directory first
sudo mkdir -p /usr/local/lib
Then make the file and restart apache
sudo touch /usr/local/lib/php.ini
and BiNgO you have a PHP.ini file ;-)
-
rebol meets apache on MacOS X
2002-02-26 12:38:26 usaps [View]
Well, first hello...
Kevin Hemenway... Very cool articles! I'm really learning a lot; but I've got a little problem I cannot make OS X Apache run my Rebol scripts... i really cannot!
I need help...
THANKS in advance.
jero
-
Appreciation
2002-02-24 17:58:43 mgoins11 [View]
Thank You for offering this series. It has been very educational to this newbie. I'll anxiously wait to see where ti goes next.
-
Installing the imap extension for php
2002-02-23 04:11:18 kkohler [View]
First of all congratulations for this great tutorial. I really learned a lot. The only thing I'm still working on ist how to install the IMAP extension for php on Mac OS X. Can anybody help me?
Thanks Klaus Kohler -
Installing the imap extension for php
2002-02-25 08:26:54 Morbus Iff |
[View]
Klaus,
The next planned in the series (part 5) will be about installing MySQL and PostgreSQL databases. As part of that, we'll be taking a quick look at recompiling PHP. I'll see if I can make mention of the IMAP extension. Just be on the lookup for the fifth article (which should be out in a few weeks).
-
Outside users can't connect
2002-02-03 00:22:04 audiophyle [View]
I am new to web serving, so please excuse me if I miss something seemingly obvious.
I have several computers connected to a Linksys Etherfast Wireless Access Point + Cable/DSL Router with 4 port switch, including a Powerbook using Airport, a PowerMac G4, and two Windows PCs. This is connected to a Cisco DSL Router, which receives a dynamically assigned IP address. I started the Apache server just fine, and I can access the web pages fine since I'm on the LAN, but outside users cannot access this website. I realize that this probably has something to do with the dynamic IP address, and the firewall created by my Linksys device, but how do I get around this? What do I need to do in order to have a web server that everyone can see? -
Outside users can't connect - me too
2002-02-03 03:26:06 pattyb777 [View]
Thanks for posting this. I too have a PC and a Mac networked with a router (SMC) and airport base station. My Mac's IP address is dynamic and my router has a firewall. I can't see what's on my apache web server on my other computer. There must be a way around this!
Patty -
Outside users can't connect - me too
2002-02-06 07:42:16 swanilda [View]
Same problem here. I went to the URL for the IP detection. http://www.checkipdyndns,org, got the actual IP address I am using as opposed to the router's, but I still can't get past the firewall. Perhaps there are settings regarding this? -
Outside users can't connect - me too
2002-03-03 00:49:45 piddle_spank [View]
i am on Cable with router PCs and Macs ect. i still have not figured this out yet but heres what i have done so far.
in the router software i have put fixed mapping on my IP so that always get the same IP.
opened ports 80 + 999 on my firewall. then changed the httpd_conf.pm file so that it trys port 999 instead of 80.
made my computer a 'DMZ' which means its no longer protected by the routers firewall.
but still no luck :(
-
Web Server won't start - please help
2002-02-02 14:32:51 pattyb777 [View]
I've been doing this series and loving it, but I think I made mistake in my httpd.conf file. The last time I stopped and started the web server, it tried to start but never actually started. It just keeps saying it is starting.
The section in question is as follows:
============
DocumentRoot "/Library/WebServer/Documents"
#
# Each directory to which Apache has access, can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# permissions.
#
<Directory "/">
Options Indexes FollowSymLinks MultiViesw
AllowOverride None
Order allow,deny
Allow from all
</Directory>
==========
When empowering SSI, I edited this section by mistake. Can someone please check their file to see what it should say?
The other changes I made were to add these lines at the end of the other lines like them:
LoadModule php4_module libexec/httpd/libphp4.so
AddModule mod_php4.c
and uncomment these lines:
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
All help will be appreciated! -
Web Server won't start - please help
2002-02-02 21:23:01 rudar [View]
Just started playing with this today, so I'm not sure I can spot the mistake right off. But if you run 'apachectl configtest' from the command line, it will tell you which line the syntax error's on...
-
checked back up file - d'oh!
2002-02-03 03:23:04 pattyb777 [View]
I didn't need the quotes around the slash in the directory listing. Forgot I had a back up file! All is well, thanks!
Patty
-
Why two httpd.conf files?
2002-02-01 12:14:56 galt606 [View]
I was reading the documentation for OS X Server and came across /private/etc/httpd/httpd.conf. Which one is for what? Why are there two? Does it make a difference? WHAT IS GOING ON HERE!?! -
Why two httpd.conf files?
2002-02-01 14:37:21 Morbus Iff |
[View]
It does not make a difference. /private/etc and /etc point to the same place - it's like an alias (in Linux, it's called a "symlink").
-
PHPost works - but does not display correctly
2002-01-30 14:29:07 cpaulu [View]
I downloaded PHPost and got it to work, but it does not correctly display the text (e.g., "username") that it pulls from the language file "phpost_English.inc"
Instead, everything ends up with just a "T": "T" instead of "username", "T" instead of "password", "login" etc.
I tried changing the language, and it didn't work either.
Anyone know what this is about?
-
PHPost works - but does not display correctly
2002-01-31 14:43:49 Morbus Iff |
[View]
I don't, unfortunately. I mainly chose PHPost as an example in the article, because it didn't use any sort of database, which would have made it a bad example. Your best bet, unless someone else answers here, is to contact the author directly.
-
Missing LoadModule php4
2002-01-30 09:17:51 stepgo [View]
I've have the same problem as a previous post. I don't have the lines LoadModule php4_module an AddModule etc...
Can I add these lines to the config code?
If so could you tell me in what order they must be ?
Thanx
PS I've just found this site and it's great
-
OK we can add these....
2002-01-30 09:23:27 stepgo [View]
But on what line exactly ? -
OK we can add these....
2002-01-30 13:56:31 Morbus Iff |
[View]
Two different places, actually.
Add the "LoadModule" line as the last of the "LoadModule" lines in your httpd.conf (you should see a good 20 of 'em in a row).
The AddModule line follows the same mentality. Look for a bunch of AddModule lines, and add the "AddModule" php line to the end of them. -
OK we can add these....
2002-02-21 21:55:28 mkullman [View]
I tried this and when I restarted my server it hangs
The error log reports the following
[notice] caught SIGTERM, shutting down
when I comment out these lines the server restarts with no problem???? -
OK we can add these....
2002-01-31 12:20:59 stepgo [View]
Super Thanxs !!!
Keep up the good work.
-
Apache to Classic
2002-01-28 10:51:59 fallenaristocrat [View]
Can I run Classic and IE in Classic (not in OSX) and connect to the Apache server.
I tried and got kernal panic - I actually had to restart OSX for the first time
REASONS - I want to develop in shockwave
(Director) and theres no plug-in for OSX yet.
regards -
Apache to Classic
2002-01-28 11:16:00 Morbus Iff |
[View]
I coulda swore Macromedia just came out with Shockwave for OS X - be sure to check VersionTracker.com on that one.
As for the Classic to OS X, yes, you can, but you may have to use your actual IP address when trying to view the pages.
Since Classic is an emulator, it might get its own "localhost" and "127.0.0.1" -- different than the "localhost" and "127.0.0.1" used by OS X. In that case, if you were in Classic IE and tried either of those, it'd look for a Classic server, and not the one you have running under OS X. -
Apache to Classic
2002-01-29 08:44:05 fallenaristocrat [View]
>>Macromedia just came out with Shockwave for OS X.
I checked. You're right it's just out.
Director for OSX next? - if so quite a coup.
regards
-
please do an article on mysql on osx
2002-01-26 13:43:25 dan@visual-contact.com [View]
I'd really like to see an article on configuring mysql on os x with php. I have had no problem getting php up and running, but mysql is giving me all kinds of problems. I can't get them to play well together.
/dan -
i have a question
2003-07-14 18:10:11 anonymous2 [View]
i have a question mr dan i'm a good writer or i mean typer and i was wondering what is a mysql os z w/ php?????
-
please do an article on mysql on osx
2002-02-03 13:09:58 brucefor [View]
Totally agree and article on mysql for os x would be great.
I have been very impressed to date by the quality and information presented in you articles. Keep up the great work!
Cheers
Bruce
-
Apache Web-Serving-Mac OS X: Part: ALL
2002-01-26 13:12:35 hylas [View]
Thank you for quality subject, manner and solid ground floor reporting - instruction.
Refreshing.
Hylas
-
Another vote to continue
2002-01-23 15:12:26 djwudi [View]
Hey Morbus -
Just another vote to continue. Thanks for what we've got so far...looking forward to more.
Now I just need to go get a couple books on php/sql and see if I can get the monstrosity cooking in my brain to come to fruition...lol :)
-
Linux and X Windows programs
2002-01-22 17:46:38 skinnywhitegeek [View]
I'd like to learn how to quickly get Linux and X windows programs to run under OS X (programs from freshmeat.net, for example). -
Linux and X Windows programs
2003-07-26 00:21:35 anonymous2 [View]
want to know about x windows
-
Excellent series by the way
2002-01-22 17:48:05 skinnywhitegeek [View]
:^]
-
PHPost
2002-01-18 14:42:43 radionerd [View]
Anyone know what permissions the PHPost files have to be in? I keep getting permission errors when accessing http://myserver.com/phpost.php
Such as:
Warning: unable to create file phpost_temp/3c48a474c3bb55.20162004.cookie because Permission denied in /Library/WebServer/Documents/phpost/phpost.php on line 432
I've made all the phpost files have the exact same owner/group settings as the default index.html file that comes with OS X.
Help? -
PHPost
2002-01-20 13:15:25 Morbus Iff |
[View]
In this error, PHPost isn't able to write/create to the phphost_temp directory because the permissions are too restrictive. In most cases, directories should be 755 (or 777) - which allows the webserver to writer/create files there. I ran across similar errors when I was testing PHPost. -
PHPost
2002-01-21 13:00:09 radionerd [View]
Yup, that was it. 755 didn't quite cut it, so I used 777. I should have checked that to start with!
Thanks for the solution! Hopefully your next article is coming out soon.... :)
-
Let's get to MySQL!!
2002-01-18 13:42:46 radionerd [View]
I'd love to see an article on the installation and a simple tutorial on creating a database.
If we all survive that, an article on interfacing PHP with our simple database would be fantastic.
I've become so sick of the lack of speed FileMaker has when interfaced with Lasso or it's own web companion, I would love the oppertunity to learn more about SQL and PHP.
THANKS! -
Let's get to MySQL!!
2002-03-04 18:40:01 ronmtec [View]
I second the motion. I do a bunch of Filemaker work and I'd like to see both sides - how we can use Filemaker with OSX (the unix-y nougat core) and other alternatives (sql) for lesser budgets (Filemaker Unlimited is $1000! as is the Filemaker server.) -
Try FrontBase (imports direct from FM)...
2002-01-30 14:57:42 mmalc [View]
FrontBase (www.frontbase.com) is an industrial strength database that supports PHP (and transactions...). PHP installation and configuration instructions are available at:
http://www.frontbase.com/download/PHP4/index.html
It's free for developers; for a wide variety of tasks it's faster than Oracle; and it includes a FileMaker import utility:
http://www.frontbase.com/download/FM2FB/macosx.html
-
You can do PostgreSQL right now
2002-01-26 05:04:58 fitz22 [View]
Step by step - I was up and running in a few minutes:
http://www.entropy.ch/software/macosx/postgresql/
Jeff
-
My config file is different
2002-01-18 13:40:29 radionerd [View]
I don't have the following in my config file:
# LoadModule php4_module libexec/httpd/libphp4.so
# AddModule mod_php4.c
I just simply added it and everything is working darn spiffy.
Any idea why it was missing? -
My config file is different
2002-01-30 09:21:15 stepgo [View]
I Have the same prob.
Where and and in what order did you add these missing lines? -
NEVERMIND
2002-01-18 13:44:46 radionerd [View]
I should have read a few more notes below, obviously I wasn't the only one with this issue.
-
GatesMcFaddenCo must Live!
2002-01-17 07:42:51 haligan [View]
Absolutly great article. Please continue this series. Don't let GatesMcFaddenCo fall like so many other dot.coms.
Michael B. -
GatesMcFaddenCo must Live!
2002-01-17 10:05:54 Morbus Iff |
[View]
Bwahahah. Ok. That was priceless.
-
Yes, please do a MySQL w/ Apache article
2002-01-16 17:43:18 donncha [View]
Thanks for the great & informative articles. Please continue with a "Configuring MySQL with Apache" and also a "Configuring Tomcat with Apache" for OS X. Please? -
Yes, please do a MySQL w/ Apache article
2002-02-02 14:21:07 pattyb777 [View]
Yes, please! That is what I want to learn next too.
-
Can't activate PHP4
2002-01-14 07:16:42 hammer09 [View]
I am at the point where I need to uncomment the LoadModule and AddModule lines but I am unable to find those modules. I see a list of a bunch of other modules but the PHP4 module is not listed under load or add. Am I doing something wrong? -
Can't activate PHP4
2002-01-14 12:57:11 Morbus Iff |
[View]
What version of OS X are you using? I think PHP was absent from the earlier versions (the articles assume 10.1.1 or 10.1.2).
-
RE:Can't activate PHP4
2002-01-15 09:55:26 hammer09 [View]
I am running 10.1.2 but after snooping around a bit I ended up making a copy of my httpd.conf.bak file and renaming it to httpd.conf and it worked. the .bak file had all of that php information in it but my original conf file did not. Any idea's what may have caused that? I am positive that I didn't delete those lines manually. Either way thanks for your response. -
RE:Can't activate PHP4
2002-01-15 12:24:52 Morbus Iff |
[View]
I don't, not just yet, but after going over everything last night, it seems that it is a relatively common occurence. Counting you, I can put my fingers on three or four people who had the exact same problem - the PHP lines missing from the conf file, but available in a backup.
I can take a stab at a possibility: that the httpd.conf file was the one from an earlier version of OS X, and that when people upgraded to the newest version of OS X, it never correctly plopped the new file in the right place. That's a long shot though - if that were the case, why the ".bak" extension on the new file? Doesn't make sense.
Either way, glad it's working for you. -
RE:Can't activate PHP4
2002-04-06 10:08:38 scottfeldstein [View]
Alas, I'm too bold for my own good. I ran into the very same problem and instead of looking down here in the discussion for an answer, I found the httpd.conf.default file contained the missing items. So... I changed it instead of the httpd.conf file as the article suggested. Somehow this resulted in a bad thing. When my machine boots I see the Apache Web Server loading...when I log in and visit the Web Sharing button I find it's "off"...when I try to turn it on it won't go. And the server isn't on. Doesn't serve a thing.
On a brighter note, after having read this discussion I was able to set up Apache, PHP and CGI sucessfully on my TiBook. Now how in heck will I fix my desktop machine? Woe is me. -
RE:Can't activate PHP4
2002-01-15 09:58:31 hammer09 [View]
Oh and one last thing. These articles kick a$$! Please keep the series going and keep up the great work. This is exactly what I have been looking for!
-
Please continue this series!
2002-01-11 19:23:45 rkd [View]
This series of articles is what I have always wanted: a bare bones, plain english how-to on Apache and it's modules and the fact that's it's for OS X is a plus! -
Please continue this series!
2002-01-16 08:00:27 rmo966 [View]
Wonderful piece of writing! Bravo! Let's dive into the next series! -
Please continue this series!
2002-01-19 21:51:08 samvenning [View]
Yes. Excellent article - very well written... very clear. Please continue the series. Last year at uni I covered HTML, Apache and PHP. First semester this year is SQL. Perfect timing for me... I'd love to get SQL up and running on MacOS 10.1.2. MacOS 10.x is now an even better web development platform! O'Reilly is proving indispensable in helping me to make the most of this system.
Sam V.
Melbourne, Australia
-
OS X, Apache and Zope
2002-01-10 05:47:46 martinb9999 [View]
What would be good is two things:
1) A tutorial on Zope & OS X
2) A tutorial on integrating Apache and Zope on OS X (it apparently needs Apache http.conf options) -
OS X, Apache and Zope
2002-01-16 14:30:55 dondi [View]
Zope works like a dream on Mac OS X. A tutorial on building and using Python on Mac OS X would come before Zope on Mac OS X. I prefer mod_fastcgi in integrating Zope and Apache. All this takes is a few edits in Apache's httpd.conf file and Zope's start script.
This series is excellent in explaining everything in a way that is easy to grasp to even a beginner. I like the progression of this series. It's not too complicated.
-
Please continue - best articles on the web!
2002-01-10 03:54:59 bob30 [View]
I spent a whole day trying to work out setting up PHP with lots of conflicting info on the web. I managed to do it on my own BUT these articles are fantastic, well explained and they work... many thanks and please keep going, especially mySql, databases with PHP and also looking at registering a domain name and making it link up to our own humble server...
regards bob
P.S. Some of my PC web developers are now seriously thinking about buying Macs...
-
YES YES YES
2002-01-09 19:15:57 josecord [View]
Please continue!!!!
My development plan include exactly the articles you mentioned: secure server and htaccess as well as MySQL .
saludos from Caracas -
YES YES YES
2003-08-19 18:54:37 anonymous2 [View]
Jose Cord, mi nombre es Ezequiel Maudet.
Estoy tratando de ubicarte por el sitio de Torotrac.
Por favor enviame tu correo electronico o telefono para ponernos en contacto.
Saludos y gracias
Ezequiel
-
Please Continue
2002-01-09 12:23:05 eyelet [View]
------------------------------------------------------------------------This is an excellent series.
Thanks
John Kulesza
-
Please continue
2002-01-09 12:20:29 eyelet [View]
This is an excellent series.
Thanks
John Kulesza
-
missing something...
2002-01-08 17:54:21 ryentzer [View]
"# LoadModule php4_module libexec/httpd/libphp4.so
# AddModule mod_php4.c"
These lines are not in my httpd.conf file. I've searched it through about 30 times.
I did a search on my harddrive for "php" and there is a folder with many .php files so I "think" i have it installed. I did this on an os 10.1.2 mac at work with no problems. I have the same OS version at home? any ideas?
-
Continue!!!
2002-01-05 23:42:59 Joe [View]
Please continue - I'd love to see more detail on installing MySQL, Postgres, or some other free-and-darned-good database.
In addition, it would be wonderful to have an updated article on enabling webDAV through Apache in MacOS X
-
more please
2002-01-05 20:58:22 erika1 [View]
I appreciate the accuracy and succinctness of this series. I've tried other web tutorials that led me astray. Had to restore the http.conf file from the default. In contrast, these lessons yield expected results.
Please delve deeper into integrating despirate applications and langages (i.e. MySQL and PHP would be a dream come true). I'd like to articulate, rather than mumble, about OSX's unixeness.
Thanks much for what you've written so far.
Erika -
adding my support
2002-02-11 22:34:32 theg [View]
kin I 'ave s'more please?
-
Please continue series!
2002-01-05 11:25:56 cms7912 [View]
These have been excellent articles. Please continue the series with, at least, a discussion of setting up and accessing a free database such as mySQL.
Great work! -
Please continue series!
2002-01-19 21:54:47 samvenning [View]
Yes. Excellent article - very well written... very clear. Please continue the series. Last year at uni I covered HTML, Apache and PHP. First semester this year is SQL. Perfect timing for me... I'd love to get SQL up and running on MacOS 10.1.2. MacOS 10.x is now an even better web development platform! O'Reilly is proving indispensable in helping me to make the most of this system.
Sam V.
Melbourne, Australia
-
Continue series!!!
2002-01-05 03:28:05 eatons [View]
" Most PHP applications require a sophisticated database backend, like MySQL or Postgres -- PHPost is one of the few that doesn't. While installing and configuring these database systems is relatively easy on Mac OS X, it would be outside the scope of this primer. Want to see an article on this?"
=============
In a word ...Yes!
Great series Kevin (...but of course, it's from O'REILLY).
Take it from a Mac-head who knows just enough Unix to be dangerous. eatons@ART-WPAg.com
-
Apache with OSX
2002-01-05 00:23:15 smithac9 [View]
Thanks for this series of articles - this is excellent stuff.
I'd like to see articles on using the various types of scripting languages to react to forms, change HTML, etc.
Also, it would be good to bring together postgresql, java and apache to show a way of getting data into an html page.
Alan Smith -
Apache with OSX
2002-01-16 10:20:25 ryentzer [View]
i agree. and yes please continue the series!










