I will try to give as much info as I can with a view to saving ppls time asking me, "Did you try... ?", when the answer almost certainly is, yes I did.
PHP 5.3, MySQL 5.1, Apache 2.2, Windows 7.
Everything is installed and working fine--EXCEPT when I try to connect to MySQL I get the message: 'Call to undefined function mysql_connect()'
The code is written correctly:
$link = mysql_connect(localhost, root, xyz1);
if(!$link) {
die('Failed to connect to server: ' . mysql_error());
}
Yes I have included all three to the PATH, all directories are named correctly, I have uncommented what needs to be uncommented in the PHP.ini file, copies are in Windows system and system32, libmysql.dll
is NOT included in PHP 5.3 (gawd knows why) but I have taken it from PHP 5.2 and copied into the PHP
and the PHP/ext folders and system32.
TheLoadModule php5_module "C:/Program Files (x86)/PHP/php5apache2_2.dll" is in httpd.conf.
I have done EVERYTHING and still I only get 'Call to undefined function mysql_connect()'
I don't know how much time I have spent on this but I AM GOING APE SHIRT over it.
phpinfo does not show anything under Modules, and only mentions MySQL where it happens to display
the PATH.
Does anybody really KNOW how to make this work?