{"id":1084,"date":"2016-11-15T10:15:08","date_gmt":"2016-11-15T10:15:08","guid":{"rendered":"http:\/\/invisiblezero.net\/?p=1067"},"modified":"2024-07-22T09:21:32","modified_gmt":"2024-07-22T09:21:32","slug":"start-php-builtin-server-for-a-project-without-apache","status":"publish","type":"post","link":"http:\/\/ndthanh.com\/start-php-builtin-server-for-a-project-without-apache\/","title":{"rendered":"Start PHP builtin server for a Project without Apache"},"content":{"rendered":"
To PHP developer, setting up new development environment is a repetitive job, it’s boring and take time when you want to test something quick on system that’s not yours. luckily, PHP include a built in server out of box from version 5.6 and today i’m going to show you how to execute it.<\/p>\n
first, you will need a php project with index.php file. Then use terminal emulator to go to project root and execute this command :<\/p>\n
\nphp -S localhost:8080\n<\/pre>\nYou can now\u00a0 access your project at this address on your browser : localhost:8080 , just simple like that.<\/p>\n
Default entry point is index.php, but you can access other file.<\/p>\n
<\/p>\n
This is good to see all requests come in or error. Can be used on the fly for quick debugging. hope you find it useful \ud83d\ude42<\/p>\n","protected":false},"excerpt":{"rendered":"
To PHP developer, setting up new development environment is a repetitive job, it’s boring and take time when you want to test something quick on system that’s not yours. luckily, PHP include a built in server out of box from version 5.6 and today i’m going to show you how to execute it. first, you…<\/p>\n