php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #55109 Friendly log messages
Submitted: 2011-07-01 21:13 UTC Modified: 2015-03-04 17:22 UTC
Votes:2
Avg. Score:2.5 ± 0.5
Reproduced:0 of 1 (0.0%)
From: arpad@php.net Assigned: moriyoshi (profile)
Status: Closed Package: Built-in web server
PHP Version: trunk-SVN-2011-07-02 (SVN) OS: N/A
Private report: No CVE-ID: None
 [2011-07-01 21:13 UTC] arpad@php.net
Description:
------------
- Compacts messages to one line, so a 404 doesn't occupy three lines.
- Includes the response status code
- Colours messages according to their response code (success=green,
client error=yellow, server error=red)
- Appends the error message when there's a fatal PHP error

Test script:
---------------
...

Expected result:
----------------
http://spellign.com/patches/cli-after.png

Actual result:
--------------
http://spellign.com/patches/cli-before.png

Patches

php-trunk-cli-server-colors3 (last revision 2011-07-02 15:29 UTC by arraypad at gmail dot com)
php-trunk-cli-server-colors2 (last revision 2011-07-02 01:16 UTC by arraypad at gmail dot com)

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-07-01 21:20 UTC] arraypad at gmail dot com
Discussion: http://marc.info/?l=php-internals&m=130930069207940&w=2

NB. Patch is not ready to be applied yet - still looking into means of excluding apparently compatible (but not) terminals.
 [2011-07-01 22:46 UTC] sixd@php.net
-Package: CGI/CLI related +Package: Built-in web server
 [2011-07-02 11:35 UTC] arraypad at gmail dot com
Added value of On to php.ini-development and php.ini-production, and changed the default value to Off (so php -n -S ... doesn't use the colours.)

I haven't found a better way of checking the terminal, so I think this patch is ready.
 [2011-07-03 09:27 UTC] felipe@php.net
-Status: Open +Status: Assigned -Assigned To: +Assigned To: moriyoshi
 [2011-07-19 13:47 UTC] moriyoshi@php.net
Automatic comment from SVN on behalf of moriyoshi
Revision: http://svn.php.net/viewvc/?view=revision&revision=313441
Log: - Print HTTP method as well in the log.
- Print response code also when the request is processed by a script.
- Those changes partly closes #55109.
 [2011-08-29 21:59 UTC] arpad@php.net
Automatic comment from SVN on behalf of arpad
Revision: http://svn.php.net/viewvc/?view=revision&revision=315748
Log: add friendly log messages (req #55109)
 [2015-03-04 17:22 UTC] reeze@php.net
-Status: Assigned +Status: Closed
 [2015-03-04 17:22 UTC] reeze@php.net
already been implemented
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 12:01:31 2024 UTC