From c8360e619b03235e5b7fc5272f0a6722707d2312 Mon Sep 17 00:00:00 2001 From: Klaus Hartl Date: Sun, 1 Feb 2009 21:09:02 +0000 Subject: Tabs: Fixed IE bug which would mistake tabs as ajax with dynamically created HTML, fixes #4033 --- ui/ui.tabs.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ui') diff --git a/ui/ui.tabs.js b/ui/ui.tabs.js index e02e61c30..224c2d9bc 100644 --- a/ui/ui.tabs.js +++ b/ui/ui.tabs.js @@ -62,6 +62,10 @@ $.widget("ui.tabs", { var fragmentId = /^#.+/; // Safari 2 reports '#' for an empty hash this.$tabs.each(function(i, a) { var href = $(a).attr('href'); + + // For dynamically created HTML that contains a hash as href IE expands + // such href to the full page url with hash and then misinterprets tab as ajax... + if (href.split('#')[0] == location.toString().split('#')[0]) href = a.hash; // inline tab if (fragmentId.test(href)) -- cgit v1.2.3