johannes Tue Sep 20 18:17:35 2005 EDT Modified files: /php-src/ext/standard credits.c Log: - Remove HTML fragments from phpcredits() in CLI mode http://cvs.php.net/diff.php/php-src/ext/standard/credits.c?r1=1.38&r2=1.39&ty=u Index: php-src/ext/standard/credits.c diff -u php-src/ext/standard/credits.c:1.38 php-src/ext/standard/credits.c:1.39 --- php-src/ext/standard/credits.c:1.38 Thu Aug 11 20:17:26 2005 +++ php-src/ext/standard/credits.c Tue Sep 20 18:17:34 2005 @@ -17,10 +17,11 @@ +----------------------------------------------------------------------+ */ -/* $Id: credits.c,v 1.38 2005/08/12 00:17:26 sniper Exp $ */ +/* $Id: credits.c,v 1.39 2005/09/20 22:17:34 johannes Exp $ */ #include "php.h" #include "info.h" +#include "SAPI.h" #define CREDIT_LINE(module, authors) php_info_print_table_row(2, module, authors) @@ -28,11 +29,15 @@ */ PHPAPI void php_print_credits(int flag TSRMLS_DC) { - if (flag & PHP_CREDITS_FULLPAGE) { + if (!sapi_module.phpinfo_as_text && flag & PHP_CREDITS_FULLPAGE) { php_print_info_htmlhead(TSRMLS_C); } - PUTS("<h1>PHP Credits</h1>\n"); + if (!sapi_module.phpinfo_as_text) { + PUTS("<h1>PHP Credits</h1>\n"); + } else { + PUTS("PHP Credits\n"); + } if (flag & PHP_CREDITS_GROUP) { /* Group */ @@ -46,7 +51,11 @@ if (flag & PHP_CREDITS_GENERAL) { /* Design & Concept */ php_info_print_table_start(); - php_info_print_table_header(1, "Language Design & Concept"); + if (!sapi_module.phpinfo_as_text) { + php_info_print_table_header(1, "Language Design & Concept"); + } else { + php_info_print_table_header(1, "Language Design & Concept"); + } php_info_print_table_row(1, "Andi Gutmans, Rasmus Lerdorf, Zeev Suraski"); php_info_print_table_end(); @@ -117,7 +126,7 @@ php_info_print_table_end(); } - if (flag & PHP_CREDITS_FULLPAGE) { + if (!sapi_module.phpinfo_as_text && flag & PHP_CREDITS_FULLPAGE) { PUTS("</div></body></html>\n"); } }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php