eddy556 Posted May 21, 2008 Share Posted May 21, 2008 Hi, Here is my system config: Apache 2.2.4 (Win32) PHP 5.2.3 MySQL 5.0.45 Community Edition (GPL) I cannot for the life of me get PHP and MySQL to interact with each other, here are the steps I have taken so far: Edited PHP.iniChanged the extension_dir = "C:\Program Files\PHP\extensions\" to the path where my extensions are Uncommented the line: extension=php_mysql.dll I have checked that both php_mysql.dll (36KB) and libmysql.dll (1484KB) are in the folder C:\Program Files\PHP\extensions and that this folder has been referenced in the PATH variable in environment variables (and server restarted). The error message that keeps getting returned is: PHP Warning: PHP Startup: Unable to load dynamic library 'C:/Program Files/PHP/extensions/php_mysql.dll' - The specified module could not be found.\r\n in Unknown on line 0 Any ideas? I have been trying to fix this for months now Quote Link to comment https://forums.phpfreaks.com/topic/106644-solved-mysql-and-php-on-apache/ Share on other sites More sharing options...
PFMaBiSmAd Posted May 21, 2008 Share Posted May 21, 2008 The path to the php root folder needs to be added to the Windows path statement. In your case - C:\Program Files\PHP The path to the extension folder does not need to be added to the Windows path statement. There are some auxiliary dll's that mysql uses that are in the php root folder, but the programmers forget to add unique error messages to tell you that the problem is due to not finding a different file. Quote Link to comment https://forums.phpfreaks.com/topic/106644-solved-mysql-and-php-on-apache/#findComment-546628 Share on other sites More sharing options...
eddy556 Posted May 21, 2008 Author Share Posted May 21, 2008 Okay, I have referenced the root PHP folder in the PATH and restarted my machine. To ensure this has worked I have copied to path below from phpinfo(): C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\PHP; This, from what I can see, should be okay. However the error still occurs. I may be missing one of the auxiliary dlls? Quote Link to comment https://forums.phpfreaks.com/topic/106644-solved-mysql-and-php-on-apache/#findComment-546769 Share on other sites More sharing options...
PFMaBiSmAd Posted May 21, 2008 Share Posted May 21, 2008 I just reread your first post. What method did you use to get php? The .zip package or the .msi installer? Everyone who I have seen use the .msi installer has had problems. When you unzip the php .zip package the extension dll's are in a folder named "ext". There is no need to do anything other than move the whole resulting php folder to where you want it. The libmysql.dll should have been in the php root folder. I recommend reading wildteen88's and my posts in this thread - http://www.phpfreaks.com/forums/index.php/topic,189883.0.html Quote Link to comment https://forums.phpfreaks.com/topic/106644-solved-mysql-and-php-on-apache/#findComment-546784 Share on other sites More sharing options...
eddy556 Posted May 21, 2008 Author Share Posted May 21, 2008 Your posts really helped! Thanks! The problem is completely sorted now, it appears I was just missing some extra dlls. I just copied them all from the ext folder of the download....I'm guessing I did use the msi to install PHP. Thanks alot Quote Link to comment https://forums.phpfreaks.com/topic/106644-solved-mysql-and-php-on-apache/#findComment-546838 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.