Subject: Re: Apache, PHP and Postgresql
To: Roland Illig <>
From: Luke Maurits <>
List: pkgsrc-users
Date: 03/08/2007 14:18:03
Thanks for that.  It turned out that the web server was indeed using
an old binary.  I had uninstalled an older version of PHP and then
installed a newer one.  I restarted apache after this, and numerous
times while trying to figure out what was going on, but apache kept
reporting it was using the old version.  In the end all I had to do
was actually stop apache and then start it again - this loaded the new
binary and everything worked a treat.  I guess I shouldn't have
assumed that a restart was sufficient to take care of a change like

Thanks again,

On 3/6/07, Roland Illig <> wrote:
> Luke Maurits wrote:
> > I'm fairly new to web programming, so to get used to things I have
> > written a small .php page which queries a postgresql database and
> > displays the results, formatted as HTML.  If I run this program from the
> > command line, i.e. execute "php filename.php", then everything appears
> > to run smoothly - the expected HTML is printed to the standard output
> > and it includes exactly those results from the database that I expect.
> What happends if you try "/usr/pkg/libexec/cgi-bin/php filename.php"?
> (Just to make sure the web server is using the correct binary.)
> Roland

( )  ASCII ribbon campaign against
 X   HTML email & proprietary format
/ \  file attachments

Please don't send me Microsoft Word documents:

Free Software Foundation:  "Free as in Freedom"

Mozilla Firefox: The browser you can trust

Mozilla Thunderbird: Reclaim your inbox

Open Office: Free, portable, compatible office suite