From e55a937093fe636c2d3b053cf3944074aeaf55e2 Mon Sep 17 00:00:00 2001 From: Rob Church Date: Sun, 1 Apr 2007 16:10:50 +0000 Subject: [PATCH] * (bug 9472) Invalid XHTML on cached query pages * Use CDATA comment stuff in OutputPage::addInlineScript() as opposed to --- RELEASE-NOTES | 1 + includes/OutputPage.php | 2 +- includes/QueryPage.php | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index af661c4377..777abec41f 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -295,6 +295,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 9241) Handle edit section links and include size links for cached templates the same as the first transclusion. * (bug 9466) "Rollback failed" page doesn't format edit comment +* (bug 9472) Invalid XHTML on cached special pages == Maintenance == * New script maintenance/language/checkExtensioni18n.php used to check i18n diff --git a/includes/OutputPage.php b/includes/OutputPage.php index ba719a90de..c932f9cf91 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -77,7 +77,7 @@ class OutputPage { */ function addInlineScript( $script ) { global $wgJsMimeType; - $this->mScripts .= ""; + $this->mScripts .= ""; } function getScript() { return $this->mScripts; } diff --git a/includes/QueryPage.php b/includes/QueryPage.php index 409a9c4bb4..75dc112c2b 100644 --- a/includes/QueryPage.php +++ b/includes/QueryPage.php @@ -307,7 +307,7 @@ class QueryPage { $updated = $wgLang->timeAndDate( $tRow->qci_timestamp, true, true ); $cacheNotice = wfMsg( 'perfcachedts', $updated ); $wgOut->addMeta( 'Data-Cache-Time', $tRow->qci_timestamp ); - $wgOut->addScript( '' ); + $wgOut->addInlineScript( "var dataCacheTime = '{$tRow->qci_timestamp}';" ); } else { $cacheNotice = wfMsg( 'perfcached' ); } -- 2.20.1