Re: RFC: built-in web server in CLI.
| From: | Jordi Boggiano | Date: | Wed, 20 Apr 2011 12:35:36 +0000 |
| Subject: | Re: RFC: built-in web server in CLI. | ||
| References: | 1 2 3 4 5 6 7 8 9 10 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-51944@lists.php.net to get a copy of this message | ||
On 20.04.2011 14:24, Johannes Schlüter wrote:
>
>
> On 04/20/11 02:05 PM, Michael Morris wrote:
>> This takes advantage of the fact that this CLI client, which
>> will*not* be
>> running as a daemon, will have an open terminal window for it for as
>> long as
>> it persists until the process is stopped with CTRL-C. Sending output to
>> that terminal window would be*very* useful in my opinion, hence the call
>> for trace. Essentially, trace is "echo" to that terminal window, or
>> "print_r" to that window if it is given an object or array.
>
> error_log() output should go there by default. (didn't check the patch)
> you can route everything there. I don't think it's good to add tons of
> extra functions for that.
I think the difference with the trace() approach is that it could be a
NOOP by default, and just print to console when running the php httpd,
so you could theoretically leave debug output in, and I will leave
everyone the liberty to interpret that as a good or bad idea.
Cheers
--
Jordi Boggiano
@seldaek :: http://seld.be/