note 39439 added to function.header
| From: | jamespilcher1-hotmail at rn2 dot php dot net | Date: | Wed, 28 Jan 2004 19:07:11 +0000 |
| Subject: | note 39439 added to function.header | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-64331@lists.php.net to get a copy of this message | ||
PHP seems to automatically change the Content-Type header of any document it processes to text/html.
If the document is something else, ie CSS you should set the header back to the correct value.
For example, if PHP is interpreting .css files in your website, you should add <?php
header("Content-type: text/css");?>
at the top of the css file, otherwise PHP outputs it's type as text/html.
this doesnt usually cause problems, but if your main document is XHTML and someone views it in
Mozilla, it won't load the stylesheet unless its content type is text/css.
----
Manual Page -- http://www.php.net/manual/en/function.header.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+39439
Delete -- http://master.php.net/manage/user-notes.php?action=delete+39439&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+39439&report=yes
Search -- http://master.php.net/manage/user-notes.php