#31284 [Com]: php mime/type
| From: | ne01026 at shark dot 2a dot pl | Date: | Tue, 17 Feb 2009 23:32:01 +0000 |
| Subject: | #31284 [Com]: php mime/type | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-133936@lists.php.net to get a copy of this message | ||
ID: 31284
Comment by: ne01026 at shark dot 2a dot pl
Reported By: teunkloosterman at gmail dot com
Status: Open
Bug Type: Feature/Change Request
Operating System: Irrelevant
PHP Version: Irrelevant
New Comment:
Actually, you get hit by this problem only if your script embedded in
HTML 4.01 code contains GREATER-THAN SIGN (>) because that is when you
cannot use the processing instruction syntax.
I think full HTML syntax should be supported,
with comment stripping and trailing comments, that is
<SCRIPT TYPE="text/php" RUNAT=SERVER ><!-- This is a PHP script
//--></SCRIPT >
Previous Comments:
------------------------------------------------------------------------
[2004-12-24 12:04:29] teunkloosterman at gmail dot com
Description:
------------
when making a php document with the <script></script> construct, you
recommend typing: <script language="php"></script> but this is widely
deprecated in html and xhtml. I think it's better to use <script
type="text/php"></script> since this is more relevant because it's used
everywhere
PS. I've also tried: application/x-httpd-php as mime/type
Reproduce code:
---------------
<html>
<head>
<title></title>
</head>
<body>
<script type="text/php">
echo "hello";
</script>
</body>
</html>
Expected result:
----------------
hello
Actual result:
--------------
javascript error
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=31284&edit=1