Re: PHP_MODE_INDENT in cgi_main.c
| From: | Zeev Suraski | Date: | Sat, 21 Jul 2001 01:10:45 +0000 |
| Subject: | Re: PHP_MODE_INDENT in cgi_main.c | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-60458@lists.php.net to get a copy of this message | ||
The status is "don't hold your breath waiting for it" :)
At 01:47 21/07/2001, Holger Zimmermann wrote:
Hi, what's the current status of the piece of code responsible for indent mode output in the CGI sapi? This snippet is from function main() #if 0-- Zeev Suraski <zeev@zend.com> CTO & co-founder, Zend Technologies Ltd. http://www.zend.com//* Zeev might want to do something with this one day */ case PHP_MODE_INDENT: open_file_for_scanning(&file_handle CLS_CC); zend_indent(); fclose(file_handle.handle.fp); return SUCCESS; break;#endif I tried it in Pi3Web and with some modification of the Content-Type - it should be "text/plain" instead of the per default used "text/html" - it seems to work. The equivalent code in pi3web_sapi.c looks like:case PHP_MODE_INDENT: header_line = (char *)estrdup("Content-Type: text/plain"); sapi_add_header_ex(header_line, strlen(header_line), 1, 1); if ( open_file_for_scanning( &file_handle CLS_CC ) == SUCCESS ) { zend_indent(); } else { iRet = PIAPI_ERROR; }; efree(header_line); break;May be this could be used in cgi_main.c too? Any comments? -- regards Holger TMTOWTDI - There's More Than One Way To Do It - Perl motto ---------------------------------------------------------- Holger 'zimpel' Zimmermann ---------------------------------------------------------- Wendishain Germany ---------------------------------------------------------- http://home.t-online.de/home/zimpel/ http://pi3web.sourceforge.net/ mailto:zimpel@t-online.de ---------------------------------------------------------- -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net