3

As a Python developer using mostly Django, I've grown accustomed to have a built-in test server for my projects, which spares me from setting up Apache for every single project I'm working on my local development machine. Is there something similar for PHP which let's me say "serve this directory as PHP project on localhost:8080"?

I'm not looking for an all-in-one-solution like XAMPP or WAMP.

Community
  • 1
  • 1
Benjamin Wohlwend
  • 30,958
  • 11
  • 90
  • 100
  • you don't need to setup a separate apache for every project. Just add an entry to your /etc/hosts, add a virtual host in httpd.conf, restart apache, done. – user187291 Sep 28 '10 at 12:47
  • I have to install and run apache in the first place and add configuration for every project. With Django, I can simply run `./manage.py runserver` and have a fully working version of my project on localhost:8000. Is there nothing similar for PHP? – Benjamin Wohlwend Sep 28 '10 at 13:11

2 Answers2

2

Looks like PHP 5.4 added this capability:

http://www.php.net/manual/en/features.commandline.webserver.php

Benjamin Wohlwend
  • 30,958
  • 11
  • 90
  • 100
1

you might want to look at http://nanoweb.si.kz/

bcosca
  • 17,371
  • 5
  • 40
  • 51