Hi everybody !
Who has not been confronted to those two error messages ?
"Unable to load dynamic library" ou "PHP can't load extension"
For those who would have this kind of problem, here is a list of possible causes with a valid solution for each one :
IMPORTANT : After any manipulation, don't forget to restart Apache service to take it into account.
------------------------------------------------------------------
- Extension is not activated in PHP configurationWay 1 : From wamp menu => PHP -> Php extensions -> name of extension (ticked)
Way 2 : Open php configuration file* and search string
extension==> Extension must be in extension list (if not, add it)
=> Extension must not begin with a semi-colon (comment)
------------------------------------------------------------------
- Extension path is incorrectOpen php configuration file* and search string
extension_dir=> Verify if path well exists
=> If path is not into quotes, add them
------------------------------------------------------------------
- Dll file does not existGo into folder containing extensions (cf extension_dir)
=> Verify that extension file well exists into this folder
------------------------------------------------------------------
- Dll file exists in several places (so in several versions)Do a windows search for this .dll file
=> Rename all corresponding files which are not in extension_dir
------------------------------------------------------------------
- Extension version is up-to-dateDownload the latest php version from site
php.net/=> Quit wampserver
=> Copy all dlls from root to folder bin/php/php_version/
=> Copy all dlls of folder ext to folder bin/php/php_version/ext
=> Relaunch wampserver
------------------------------------------------------------------
- Loaded configuration file is not the right oneOpen url
http://localhost/?phpinfo=1 and find field
Loaded Configuration File=> Verify if path is correct and correspond to your install path of wamp
(example : C:\wamp\bin\apache\apache2.2.8\bin\php.ini)
If precised file is incorrect
=> Delete this file if you don't need it
=> Add the environment variable* PHPRC which value will be the exact php.ini folder path
------------------------------------------------------------------
- Extension require other librairies to be installedExample: sybase require two external librairies, available on their website.
=> You have to enquire to know if this librairy depends of another one...
=> Download required extensions, preferably with the same version
------------------------------------------------------------------
*
Open php configuration fileLeft click on wamp icon -> PHP -> php.ini (opened with notepad)
*
Add a variable environmentControl Panel -> System (or Windows+Sleep)
In tab
Advanced, click on button
Environnement variablesIn section
System variables, click on
NewVariable name : PHPRC
Variable value : correct path (without quotes) of the right php.ini file
(example for me : C:\wamp\bin\apache\apache2.2.8\bin\ )
Valid with Ok and restart computer to take this variable into account.
------------------------------------------------------------------
If you know other problems or solutions, thanks to tell us in this topic.
If this topic helped you, please tell us which solution worked for you.
Courage for everybody
Florian
WampServer Patch (
Screenshots)
Topic EN :
www.wampserver.comTopic FR :
www.wampserver.comEdited 2 time(s). Last edit at 08/27/2009 12:55AM by toumimi.