wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 14, 2018 12:26AM

Windows10-64bit
version-3.0.6
apache-2.4.27
php-7.2.3,
mysql-5.7.1
icon-green
127.0.0.1 localhost ::1 localhost
localhost-yes
8a-no
9-yes
11-Avira
c:/wamp64

After a installing wamp, I have updated php from version 5.6.31 to version 7.2.3
LoadModule php7_module "${INSTALL_DIR}/bin/php/php7.2.3/php7apache2_4.dll"

However, the version at the top of phpinfo and in the Configuration apache2handler section says 7.1.9

I tried opening phpmyadmin (version 4.7.4), message displayed is
The mbstring extension is missing. Please check your PHP Configuration
There is no semi-colon in front of
extension=php_mbstring.dll
extension_dir ="c:/wamp64/bin/php/php7.2.3/ext/"
php_mbstring.dll is in the ext folder.

Am I missing some configuration?

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 14, 2018 09:17AM

Hi,

> After a installing wamp, I have updated php from version 5.6.31 to version 7.2.3
> LoadModule php7_module "${INSTALL_DIR}/bin/php/php7.2.3/php7apache2_4.dll"
Why are you showing this line?
Would you have changed the PHP version "by hand", by modifying the httpd. conf file yourself?

In the file wamp64/wampmanager.conf what are the content of lines:
- phpVersion =
- phpCliVersion =

> extension=php_mbstring.dll
What have you changed?
For PHP 7.2. x, it is not a line like this one that should be.

------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 14, 2018 09:48AM

I changed LoadModule by hand. I displayed that line to show what it was changed to, 7.2.3, and not 7.1.9.
In wampmanager.conf, both phpVersion and phpCliVersion were 5.6.31, I have changed them to 7.2.3
As far as the ext is concerned, I only changed the ext path from 5.6.31 to 7.2.3, the extension is active by default.
I started wamp, icon is green. Clicking on the wamp icon, PHP version is 7.2.3, its 7.2.3 in localhost, but still displaying 7.1.9 in phpinfo. I now have access to phpmyadmin.

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 14, 2018 09:58AM

Hi,

> I changed LoadModule by hand.
Huge mistake.

By doing this, you didn't change everything that should have been changed if you changed the PHP version.
The only way to change PHP version correctly is :

Left-Click Wampmanager tray icon -> PHP -> Version -> Choose version

Of course, you must first install the addons of the required PHP versions.

But, given all the changes you've made, for example by giving paths of a PHP version in the php. ini of another version, not sure if it works properly.

------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 14, 2018 10:08AM

I removed the older versions of php from the php folder, then chose the version as you mentioned, as there was only one version available 7.2.3, I chose it. Restarted wamp, phpinfo still displaying 7.1.9

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 14, 2018 11:10AM

I've also updated phpmyadmin from 4.7.4 to 4.7.9
Clicking on the wamp icon, 4.7.4 is displayed beside phpmyadmin, however, when I open phpmyadmin, its version is 4.7.9

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 14, 2018 01:49PM

I added php to windows path C:\wamp64\bin\php\php7.2.3
then in command prompt


C:\>php -v

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_bz2.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_curl.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_fileinfo.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_gd2.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_gettext.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_gmp.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_intl.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_imap.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_ldap.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_mbstring.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_exif.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_mysqli.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_openssl.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_pdo_mysql.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_pdo_sqlite.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_soap.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_sockets.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_sqlite3.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_xmlrpc.dll' - The specified module could not be found.
in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library 'c:/wamp64/bin/php/php7.1.9/ext/php_xsl.dll' - The specified module could not be found.
in Unknown on line 0
PHP 7.1.9 (cli) (built: Aug 30 2017 18:34:46) ( ZTS MSVC14 (Visual C++ 2015) x64 )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies

In php error log

[13-Mar-2018 22:30:54 UTC] PHP Warning: PHP Startup: bz2: Unable to initialize module
Module compiled with module API=20131226
PHP compiled with module API=20160303
These options need to match
in Unknown on line 0

Same for each module.

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: RiggsFolly (Moderator)
Date: March 14, 2018 05:51PM

NEVER EVER ADD the PHP folder to the windows path !!!!

See This answer on StackOverflow for how best to do this


Remember in WAMPServer you can have multiple versions of PHP available, you never want to lock yourself into only one version

---------------------------------------------------------------------------------------------
(Windows 7 Pro 32bit) (Wampserver 3.1.3 32bit & 64bit)
<Apache 2.4.29/2.2.31> <PHP 7.2/7.1/7.0/5.6/5.5/5.4> <MySQL 5.7.19/5.6.39/5.5.28>
<MariaDB 10.2.14> <phpMyAdmin4.8.1> <MySQL Workbench 6.3.10>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin -- WAMPServer alternate Repo
-?-?-?- Backup your MySQL databases regularly Here is How dont regret it later! Yes even when developing -?-?-?-



Edited 2 time(s). Last edit at 03/14/2018 05:52PM by RiggsFolly.

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 14, 2018 08:32PM

Hi,

You'd better start from scratch.
With the changes you made by hand, you screwed up the files and versions of PHP.

- Uninstall Wampserver completely.

- Verify that all VC ++ packages are installed and with the latest versions.
To do this, use the tool:
Checks VC++ packages installed
And you will find all the packages on [wampserver.aviatechno.net] in section Visual C++ Redistribuable Packages
Do not forget that if you have a 64 bit Windows, you must install both 32 and 64 bit versions of each package.
You must install each package "as an administrator", so right-click the exe file and then run as Administrator.
Do not use a previously loaded tool. Make a new download to make sure you are using the correct version.

- Install Wampserver 3.1.0
- Install PHP addons you want.

------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 15, 2018 04:23AM

I started from scratch. Installed all the necessary distributables. Re-installed wampserver. All good. I changed the phpVersion and phpCliVersion to 7.1.9 in wampmanager.conf and selected php version 7.1.9. Restarted wampserver. Clicked wamp icon, php 7.1.9. Opened localhost, php version 7.1.9, opened phpinfo, version 7.1.9, ext dir 7.1.9.
Executed php -v in cmd

C:\>php -v
PHP 7.1.9 (cli) (built: Aug 30 2017 18:34:46) ( ZTS MSVC14 (Visual C++ 2015) x64 )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies

Checked php error log.
PHP Warning: PHP Startup: Unable to initialize module
Module compiled with module API=20131226
PHP compiled with module API=20160303
These options need to match
in Unknown on line 0

for all modules.

Are these errors a config issue or something else?

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 15, 2018 10:09AM

Hi,

> I changed the phpVersion and phpCliVersion to 7.1.9 in wampmanager.conf and selected php version 7.1.9
NO. Except in very special cases of troubleshooting, never modify versions directly in the wampmanager. conf file.
For PHP CLI version
- Right-Click wampmanager tray icon -> Tools -> Change PHP CLI version [choose version]

For PHP "web" version
- Left-Click wampmanager tray icon -> PHP -> Version -> [choose version]

There is no problem with PHP 7.1.9 64 bit CLI and WEB on Windows 10 Pro 64 bit.

The errors you have made clearly show that the loaded extensions are not the ones of the declared PHP version, which means that the php. ini used is not the one of the declared PHP version.

What is the content of the environment variable PATH?
Open a command windows as an administrator ( The word Administrator must be in the command windows title) and type:
path

For ease of copying, you can send the content directly to the clipboard by typing the command:
path | clip

------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 15, 2018 11:11AM

PS C:\windows\system32> path;
path : The term 'path' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of
the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ path;
+ ~~~~
+ CategoryInfo : ObjectNotFound: (pathconfused smileytring) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException

php is not in there. I checked via CP



Edited 2 time(s). Last edit at 03/15/2018 11:31AM by rpjd.

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 15, 2018 12:03PM

Hi,

Did I put a semicolon after the PATH command?



------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 15, 2018 12:37PM

Administrator: C:\Windows\System32\cmd.exe

Microsoft Windows [Version 10.0.16299.309]
(c) 2017 Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>path
PATH=C:\Program Files (x86)\Intel\iCLS Client\;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\Hewlett-Packard\SimplePass\;C:\Program Files\MySQL\MySQL Utilities 1.6\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\Microsoft SQL Server\130\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\Tools\Binn\ManagementStudio\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\dotnet\;C:\ProgramData\ComposerSetup\bin;C:\wamp64\bin\php\php7.1.9\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files\nodejs\;C:\Users\richa\AppData\Local\Programs\Python\Python36-32\Scripts\;C:\Users\richa\AppData\Local\Programs\Python\Python36-32\;C:\Users\richa\AppData\Local\Microsoft\WindowsApps;C:\Users\richa\AppData\Roaming\Composer\vendor\bin;C:\Users\richa\AppData\Roaming\npm;C:\Program Files\Microsoft VS Code\bin

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: Otomatic (Moderator)
Date: March 15, 2018 12:57PM

Hi,

You have a path on a version of PHP in your PATH environment variable:

C:\wamp64\bin\php\php7.1.9\;

It's to be deleted. There must be no path on a version of php in the PATH environment variable.

After deleting this superfluous path, the machine must be restarted to be taken into account.

------------------------------------------------------------------------------------------------------------
Wampserver 3.1.3 32 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
Wampserver 3.1.3 64 bit - Apache 2.4.33 - PHP 7.2.4/7.1.16/7.0.29/5.6.35 - MySQL 5.7.22 - MariaDB 10.2.14
PhPMyAdmin 4.8.0 - MysqlDumper 1.24.5
on W10 and W7 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote
Re: wrong php version in phpinfo, phpmyadmin says mbstring ext missing (its not)
Posted by: rpjd (37.228.229.---)
Date: March 16, 2018 12:58AM

Got it working.

Options: ReplyQuote


Sorry, only registered users may post in this forum.