On Sep 8, 2007, at 02:19, [EMAIL PROTECTED] wrote:
Revision: 28727
http://trac.macosforge.org/projects/macports/changeset/28727
Author: [EMAIL PROTECTED]
Date: 2007-09-08 00:19:03 -0700 (Sat, 08 Sep 2007)
Log Message:
-----------
Correct the reported mime type of the web pages (application/xhtml
+xml), since they
claim to be xhtml. My server is still serving them as text/html,
however, but I guess
that's a local Apache misconfiguration.
I don't think the Apache configuration can influence that for PHP
pages. You probably just need:
<?php
header('Content-Type: application/xhtml+xml; charset=' . $encoding);
?>
at the top somewhere.
Serving as application/xhtml+xml has historically meant that you're
excluding Internet Explorer for Windows. I don't know if that's still
the case with IE7. We might not care about this since we're targeting
Mac users. Or we might care. A workaround is listed here, which I
have not tested:
http://www.w3.org/MarkUp/2004/xhtml-faq#browsers
Modified Paths:
--------------
trunk/www/includes/common.inc
Modified: trunk/www/includes/common.inc
===================================================================
--- trunk/www/includes/common.inc 2007-09-08 03:01:05 UTC (rev 28726)
+++ trunk/www/includes/common.inc 2007-09-08 07:19:03 UTC (rev 28727)
@@ -31,7 +31,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title><?php echo("$title"); ?></title>
- <meta http-equiv="Content-type" content="text/html; charset=<?
php echo("$encoding"); ?>" />
+ <meta http-equiv="Content-type" content="application/xhtml
+xml; charset=<?php echo("$encoding"); ?>" />
<meta name="author" content="Jim Mock ([EMAIL PROTECTED])" />
<meta name="author" content="Juan Manuel Palacios
([EMAIL PROTECTED])" />
<meta name="author" content="Chris Pickel
([EMAIL PROTECTED])" />
P.S: Why are we doing
echo("$encoding")
and not just
echo $encoding
? echo is a language construct, not a function, so no parens are
necessary, and there's no need to create a string just so that it can
contain one variable. Just echo the variable directly.
_______________________________________________
macports-dev mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo/macports-dev