aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Weiske <cweiske@cweiske.de>2010-10-09 12:09:39 +0200
committerChristian Weiske <cweiske@cweiske.de>2010-10-09 12:09:39 +0200
commitf359fd685f164855a34c85d164e0d38da12a2434 (patch)
tree7837d478c39156b6de8e1368a8c1fee40387dc58
parent48cd84921f42e409653ac34a5ba5c3d1d988c4e0 (diff)
downloadsemanticscuttle-f359fd685f164855a34c85d164e0d38da12a2434.tar.gz
semanticscuttle-f359fd685f164855a34c85d164e0d38da12a2434.tar.bz2
make the page valid and keep chromium happy
-rw-r--r--data/templates/sidebar.block.linked.php6
-rw-r--r--data/templates/top.inc.php3
-rw-r--r--src/SemanticScuttle/header.php5
3 files changed, 9 insertions, 5 deletions
diff --git a/data/templates/sidebar.block.linked.php b/data/templates/sidebar.block.linked.php
index db0d087..54e9260 100644
--- a/data/templates/sidebar.block.linked.php
+++ b/data/templates/sidebar.block.linked.php
@@ -32,7 +32,7 @@ if ($editingMode) {
?>
<script type="text/javascript" src="<?php echo ROOT ?>js/jquery-1.4.2.js"></script>
<script type="text/javascript" src="<?php echo ROOT ?>js/jquery.jstree.js"></script>
-<script type="text/javascript">
+<script type="text/javascript"><![CDATA[
jQuery("#related")
.jstree({
"themes" : {
@@ -48,7 +48,7 @@ jQuery("#related")
parent = "";
if (node == -1 ) {
node = <?php echo json_encode($currenttag); ?>;
- parent = "&amp;parent=true";
+ parent = "&parent=true";
} else if (node.attr('rel')) {
node = node.attr('rel');
} else {
@@ -60,5 +60,5 @@ jQuery("#related")
},
plugins : [ "themes", "json_data"]
});
-</script>
+]]></script>
</div> \ No newline at end of file
diff --git a/data/templates/top.inc.php b/data/templates/top.inc.php
index 8be978f..c3cbc5d 100644
--- a/data/templates/top.inc.php
+++ b/data/templates/top.inc.php
@@ -1,7 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
<title><?php echo filter($GLOBALS['sitename'] .(isset($pagetitle) ? ' ยป ' . $pagetitle : '')); ?></title>
<link rel="icon" type="image/png" href="<?php echo ROOT ?>icon.png" />
<link rel="stylesheet" type="text/css" href="<?php echo ROOT ?>scuttle.css" />
diff --git a/src/SemanticScuttle/header.php b/src/SemanticScuttle/header.php
index d1a5c29..3caeb35 100644
--- a/src/SemanticScuttle/header.php
+++ b/src/SemanticScuttle/header.php
@@ -120,7 +120,10 @@ $tplVars['userservice'] = $userservice;
if (!defined('UNIT_TEST_MODE')) {
//API files define that, so we need a way to support both of them
if (!isset($httpContentType)) {
- $httpContentType = 'text/html';
+ //$httpContentType = 'text/html';
+ //using that mime type makes all javascript nice in Chromium
+ // it also serves as test base if the pages really validate
+ $httpContentType = 'application/xhtml+xml';
}
if ($httpContentType !== false) {
header('Content-Type: ' . $httpContentType . '; charset=utf-8');