php and me don't get alone... help?

Madison Kelly linux-5ZoueyuiTZhBDgjK7y7TUQ at public.gmane.org
Thu Nov 30 03:30:54 UTC 2006


Hi all,

   I am trying to setup a tiny test script on Debian 
Sarge/Apache2/PostgreSQL 8.1/PHP5. Problem is, php5 doesn't have support 
for pg_connect (get the error "Fatal error: Call to undefined function 
pg_connect() in /var/www/html/index.php on line 2"). Apparently pgsql 
support is specifically excluded by default?

   I've installed 'php5-pgsql', ran 'dpkg-reconfigure php5-pgsql', made 
sure 'extension=pgsql.so' was in '/etc/php5/apache2/php.ini' and 
restarted Apache and PostgreSQL. I've tried with and without a password 
on the pgsql user... Still no luck though.

   Is this why PHP/MySQL are so popular together?

   Here is my script, in all it's glory:

<?php
$dbh=pg_connect("dbname=phpbb_mb user=digimer password=secret") or 
die("Couldn't Connect ".pg_last_error());
?>

   Crazy complex, no? *sigh* Anyone have any idea what the heck I am 
doing wrong mind hitting me a clue-stick?

Madi

--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list