httpserver icon indicating copy to clipboard operation
httpserver copied to clipboard

In Windows Not Working

Open ArunPatal opened this issue 5 years ago • 1 comments

Hi, I tried it on windows. In example_server.php i set following settings. But when going to browser 127.0.0.1:8003, am getting Internal Server Error: php-cgi\php-cgi.exe was not found error. function __construct() { parent::__construct(array( 'addr' => "127.0.0.1", 'port' => 8003, 'php_cgi' => "php-cgi\php-cgi.exe", )); }

In httpserver i changed $cgi_stream = fopen("cgi://{$this->php_cgi}", 'rb', false, $context); to $cgi_stream = fopen("$this->php_cgi", 'rb', false, $context); and am getting output somthing like binary data.

Can you please advice me how to setup it. Am using PHP 5.6 & win10

ArunPatal avatar Jul 26 '20 13:07 ArunPatal

Path to cgi was not correct. After giving absolute path it work. Is there a way to use cgi as fast-cgi? I found response time little bit slow. Also is there a way to restart or stop server? Thanks for great script

ArunPatal avatar Jul 26 '20 23:07 ArunPatal