#19098 [NEW]: header("Content-type: text/plain") does not work
| From: | michael dot mauch at gmx dot de | Date: | Sun, 25 Aug 2002 23:15:01 +0000 |
| Subject: | #19098 [NEW]: header("Content-type: text/plain") does not work | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-17810@lists.php.net to get a copy of this message | ||
From: michael.mauch@gmx.de
Operating system: Linux
PHP version: 4CVS-2002-08-25
PHP Bug Type: Apache related
Bug description: header("Content-type: text/plain") does not work
With php4-STABLE-200208251500 and php4-200208251500 the header function
does not set the Content-type if it is text/xml or text/plain or
text/something.
It works with application/xml, and it works with php-4.2.2.
# HEAD http://localhost/~elmicha/php/header_xml.php
200 OK
Connection: close
Date: Sun, 25 Aug 2002 22:47:51 GMT
Server: Apache/1.3.26 (Unix) mod_perl/1.26 PHP/4.2.2
Content-Type: text/xml
Client-Date: Sun, 25 Aug 2002 22:47:51 GMT
Client-Response-Num: 1
X-Powered-By: PHP/4.2.2
# HEAD http://localhost/~elmicha/php/header_xml.php
200 OK
Connection: close
Date: Sun, 25 Aug 2002 22:48:43 GMT
Server: Apache/1.3.26 (Unix) mod_perl/1.26 PHP/4.2.3-dev
Content-Type: text/html; charset=iso-8859-1
Client-Date: Sun, 25 Aug 2002 22:48:43 GMT
Client-Response-Num: 1
X-Powered-By: PHP/4.2.3-dev
I configured both versions only --with-apxs. The test file:
<?php
header("Content-type: text/xml");
echo "<hello></hello>\n";
?>
--
Edit bug report at http://bugs.php.net/?id=19098&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=19098&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=19098&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=19098&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=19098&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=19098&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=19098&r=support
Expected behavior: http://bugs.php.net/fix.php?id=19098&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=19098&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=19098&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=19098&r=globals