Skip to content

Quickest way to get PHP running on a Windows PC

DUONG Phu-Hiep edited this page Nov 27, 2018 · 3 revisions
  1. Download the portable (.zip) version of UWAMP
  2. Unzip it to the path\to\UwAmp\ folder so the PATH_TO_PHP_EXE is path\to\UwAmp\bin\php\php-7.0.3
  3. You will have to add this PATH_TO_PHP_EXE to the Path environment so that you can call php on command line from anywhere

Configure the php.ini:

  • create the php.ini from the existing php_uwamp.ini:
copy PATH_TO_PHP_EXE\php_uwamp.ini PATH_TO_PHP_EXE\php.ini
  • Edit the php.ini:
  1. replace {PHPEXTPATH} with PATH_TO_PHP_EXE\ext (use the absolute Path here)
  2. replace {PHPZENDPATH} with PATH_TO_PHP_EXE\zend_ext (use the absolute Path here)

Activate the php_soap extension so that you can run PHP scripts which used SoapClient

extension=php_soap.dll

You don't need to run UWAMP

Now, you should be able to run any PHP scripts locally:

php Something.php

You would also be able to run a http server locally:

php -S localhost:8000