php-mysql Connection

John Kebbel yellowdog-general@lists.terrasoftsolutions.com
Sun Feb 8 07:36:00 2004


I've built two small databases in MySQL that run fine at the command
line. I've also written several short php pages that perform fine in
Mozilla. But when I try to connect to MySQL from a php page, I get this
message: "Fatal error: Call to undefined function: mysql_connect() in
/var/www/html/php/firstMySQLConnect.php on line 13". 

This is one of many areas in L-A-M-P I'm a sub-newbie at, so I've been
stumbling in the dark with these attempts at a fix.

1) phpinfo() says this about mysql: --with-mysql=shared,/usr'
2) I couldn't find aything like extension mysql.so in the php.ini file.
3) I used yum update php to see if it would supply what my web research
says is a missing extension, but it didn't fix the problem.
4) I tried downloading and installing php-mysql-4.1.2-7.3.6a.ppc.rpm but
got this message: 
error: Failed dependencies: php = 4.1.2-7.3.6a is needed by
php-mysql-4.1.2-7.3.6a

Anyone got suggestions on how to resolve this issue? 

(The bad news is that after I fix this problem in my YDL development
environment, I've got to do the same thing with an OS 10.3 and an OS X
2.8 machine where I plan to deploy the solutions.)