6

I have XAMPP 1.8.3 installed on my windows 7 machine. Which include PHP 5.5.6. I want to upgrade the PHP to 5.6 version. Is it possible to do the upgrade while keeping the XAMPP bundle other module as it is (Apache, MySQL). Can any one suggest a way to do upgrade on windows 7.

guru
  • 309
  • 1
  • 3
  • 15

2 Answers2

11
  • Download the package from following url: http://windows.php.net/download/. Make sure the “Thread Safe” zip file with around 20MB was downloaded.
  • Extract and rename the folder to “php”.
  • Rename the existing “php” folder to something and place the new bundle with folder name “php”.
  • Then restart the apache server. It will simply load the new PHP version.
guru
  • 309
  • 1
  • 3
  • 15
  • 1
    You may also need to install C++ Redistributable as in http://stackoverflow.com/questions/30811668/php7-missing-vcruntime140-dll – M at Jul 03 '16 at 05:09
  • I had to [redownload xdebug](https://gist.github.com/odan/1abe76d373a9cbb15bed), and put it in `ext/` like last time. No hassle. – Rudie Nov 08 '19 at 22:59
4

Try like this:

How to upgrade php in xampp:-

  1. Lots of time you need to use multiple version of php for your different project. In this case either you want to install xampp on different port or you can install one xampp and upgrade php. In this article I will demonstrate how you can upgrade php in your xampp server. I will demonstrate the complete process by adding PHP 5.4 with XAMPP. Following is the step by step process of upgrading php in your xampp server. Before trying these steps please take complete backup of your code and database alognwith xampp because any small mistake can lead to the corruption of your regular XAMPP.

Upgrade PHP in XAMPP server

  1. Download PHP : If you are using xampp ofcourse you are using windows operating system. So first download your desired version of php binary from http://windows.php.net/download/ website. Be careful while choosing binary. If you are using XAMPP then your webserver is apache. So always download Thread Safe binary. Also read the compiler suggestion carefully on the windows.php.net site. I will recommend to download zip version.
  2. Configure New PHP Version with your xampp: Unzip the downloaded version of the PHP in a separate folder. Please make sure that your new php folder name is not “PHP”. May be you can use folder name as the version name. For example for php 5.4 you can use php54. Copy the new php folder into your xampp folder. Now go to yourxampp/apache/conf/extra folder. Open file httpd-xampp.conf from the folder extra. Change the following variables:

    • Variable PHPINIDir to be your xampp folder new version of PHP

    • Varaible LoadModule to be your xampp folder/new version of PHP/php5apache2_2.dll

Save the file httpd-xampp.conf. Restart your XAMPP apache server. If your server get restarted successfully then your server php version is upgraded. You can check the status of your php version by URL http://localhost/xampp/phpinfo.php .

JH_
  • 406
  • 1
  • 4
  • 15
RaMeSh
  • 3,330
  • 2
  • 19
  • 31
  • 1
    Simply place the new package folder with the name "php" is working. Why we have to go for long method. If you want backup just rename the older one. – guru May 28 '15 at 12:36
  • yes,according to our requirement we can follow methods. – RaMeSh May 28 '15 at 13:21