[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [cobalt-users] [RAQ4] PHP 4.2.3 - mySQL connect problem
- Subject: Re: [cobalt-users] [RAQ4] PHP 4.2.3 - mySQL connect problem
- From: "Steve Werby" <steve-lists@xxxxxxxxxxxx>
- Date: Wed Nov 27 06:28:01 2002
- Organization: Befriend Internet Services LLC
- List-id: Mailing list for users to share thoughts on Sun Cobalt products. <cobalt-users.list.cobalt.com>
"Leslie Herps" <mailinglists@xxxxxxxxxxxx> wrote:
> I made an RPM with success.... And I installed it... But now I get the
> following error when trying to connect to mySQL...
>
> Error:
> =====================================================
> Fatal error: Call to undefined function: mysql_connect()
> =====================================================
It means PHP isn't running with MySQL support. PHP builds with MySQL
support unless you explicitly negate it, which you didn't so what you did
below was fine.
> --with-mysql=shared
You built is a shared module. So there should be a mysql.so file somewhere,
likely /usr/lib/apache/php/mysql.so so you'd need a line like:
extension=mysql.so in php.ini.
If it's there, but with a ";" in front, remove the ";" as it's a comment
character. Then reload the Apache by doing:
/etc/rc.d/init.d/httpd reload
> Does anyone have a clue what I did wrong?
See above. Though there are pros and cons, it is probably simpler and in
many cases better to build PHP --with-mysql not as a shared module.
--
Steve Werby
President, Befriend Internet Services LLC
http://www.befriend.com/