This question already has an answer here:
-
Best way to Upgrade wamp 2.0 to 2.5
2 answers
I downloaded latest wamp server and I installed in my system with php version 5.5.12 and now I want to upgrade php version to 5.5.27 with safely.. How can I upgrade?
For someone who need to update the PHP version in WAMP, I can recommend this http://wampserver.aviatechno.net/
I had a problems with updating too, but on this website are Wampserver addons like new php version (php 7.1.4 etc.) And you don't have to manually edit files like php.ini or phpForApache.
Enjoy!
WAMP server generally provide addond for different php/mysql versions. However you mentioned you have downloaded latest wamp server. As of now, latest Wamp server v2.5 provide PHP version 5.5.12
So you need to upgrade it manually as follow:
- Download binaries on php.net
- Extract all files in a new folder : C:/wamp/bin/php/php5.5.27/
- Copy the wampserver.conf from another php folder (like php/php5.5.12/) to the new folder
- Rename php.ini-development file to phpForApache.ini
- Done ! Restart WampServer (>Right Mouseclick on trayicon >Exit)
Although not asked, I'd recommend to vagrant/puppet or docker for local development. Check puphpet.com for details. It has slight learning curve but it will give you much better control of different versions of every tool.
To add to the above answer (do steps 1-5).
- Click on WAMP -> Select PHP -> Versions: Select the new version installed
- Check that your PATH folder is updated to new path to PHP so your OS has same PHP version of WAMP.
One important step is missing in all answers. I successfully upgraded with following steps:
- stop apache service with wamp stack manager.
- rename your wampstack/php dir to wampstack/php_old
- copy new php dir to wampstack/
- replace wampstack/php/php.ini by wampstack/php_old/php.ini
- test and fix any error with php -v (for example missing extensions)
- [optional] update php version in wampstack/properties.ini
- Replace wampstack/apache/bin/php7ts.dll by wampstack/php/php7ts.dll
- This is not mentioned in the other answers but you need this to use
the right php version in apache!
- start apache service