From: Brion Vibber Date: Tue, 19 Dec 2006 20:39:43 +0000 (+0000) Subject: * Gracefully skip redirect-to-fragment on WebKit versions less than 420; X-Git-Tag: 1.31.0-rc.0~54838 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/membres/fiche.php?a=commitdiff_plain;h=4dc8d4a3f5250546bda58bd1a8144e2af8b27ade;p=lhc%2Fweb%2Fwiklou.git * Gracefully skip redirect-to-fragment on WebKit versions less than 420; it messes up on current versions of Safari but is ok in the latest nightlies. Checking the version number will allow it to automatically work when new releases of Safari appear. --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 0541e3a920..f081d6dbe1 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -348,6 +348,11 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 5411) Remove autopatrol preference; users who can mark edits patrolled will now have their edits marked as such regardless * (bug 8109) Template parameters ignored in "recentchangestext" +* Gracefully skip redirect-to-fragment on WebKit versions less than 420; + it messes up on current versions of Safari but is ok in the latest + nightlies. Checking the version number will allow it to automatically + work when new releases of Safari appear. + == Languages updated == diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 1676de61fc..84a24565c3 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -1041,7 +1041,7 @@ $wgCacheEpoch = '20030516000000'; * to ensure that client-side caches don't keep obsolete copies of global * styles. */ -$wgStyleVersion = '34'; +$wgStyleVersion = '35'; # Server-side caching: diff --git a/skins/common/wikibits.js b/skins/common/wikibits.js index 9f9a9f03a7..55fca49e0d 100644 --- a/skins/common/wikibits.js +++ b/skins/common/wikibits.js @@ -851,6 +851,15 @@ function sortableTables() { } function redirectToFragment(fragment) { + var match = navigator.userAgent.match(/AppleWebKit\/(\d+)/); + if (match) { + var webKitVersion = parseInt(match[1]); + if (webKitVersion < 420) { + // Released Safari w/ WebKit 418.9.1 messes up horribly + // Nightlies of 420+ are ok + return; + } + } if (is_gecko) { // Mozilla needs to wait until after load, otherwise the window doesn't scroll addOnloadHook(function () {