I’m trying to load a php environment with Laragon in Windows 10.
When I start Apache, in php_errors.log
file I get this warnings:
[13-Sep-2024 01:03:32 UTC] PHP Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: C:laragonbinphpphp-8.1.10-Win32-vs16-x64extcurl (No se puede encontrar el módulo especificado), C:laragonbinphpphp-8.1.10-Win32-vs16-x64extphp_curl.dll (No se puede encontrar el módulo especificado)) in Unknown on line 0
[13-Sep-2024 01:03:32 UTC] PHP Warning: PHP Startup: Unable to load dynamic library 'intl' (tried: C:laragonbinphpphp-8.1.10-Win32-vs16-x64extintl (No se puede encontrar el módulo especificado), C:laragonbinphpphp-8.1.10-Win32-vs16-x64extphp_intl.dll (No se puede encontrar el módulo especificado)) in Unknown on line 0
[13-Sep-2024 01:03:32 UTC] PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_pgsql' (tried: C:laragonbinphpphp-8.1.10-Win32-vs16-x64extpdo_pgsql (No se puede encontrar el módulo especificado), C:laragonbinphpphp-8.1.10-Win32-vs16-x64extphp_pdo_pgsql.dll (No se puede encontrar el módulo especificado)) in Unknown on line 0
When I show a phpinfo()
output, effectively curl, intl and pfo_pgsql are not loaded. But if I run php -m
in the terminal, the extensions are loaded.
C:laragonwww
λ php -m
[PHP Modules]
bcmath
calendar
Core
ctype
curl
date
...
iconv
intl
json
...
PDO
pdo_mysql
pdo_pgsql
Phar
...
The ini file is the same on CLI and Apache.
In CLI
C:laragonwww
λ php --ini
Configuration File (php.ini) Path:
Loaded Configuration File: C:laragonbinphpphp-8.1.10-Win32-vs16-x64php.ini
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
In Apache (using PHP Info)
The *.dlls files are present in the directory C:laragonbinphpphp-8.1.10-Win32-vs16-x64ext
- The others extensions load fine (e.g. mysql)
- I already reloaded Apache and restarted Windows.
- The extensions are uncommented in
php.ini
file.
The problem it was the PHP default version of Laragon package.
I try to add new PHP versions using the links of the Wiki Page, install new PHP version 8.1.29 and enable the pdo_pgsql extension, and all works fine.
Extra info: The old version of PHP in the package was 8.1.10 and not include nts in his name. The new version is 8.1.29. IDK if this is relevant.