Given the following constelation:
Page URL: MyPage.html
In the page source we have this:
The 1.7.2 version of UI.tabs does not detect that we point to ourself and loads the page twice and the result is not what we expect.
The solution is to look if the href is only a page name, and if yes, look if it's identical tou our own url.
Here the code which fixes this problem, it starts arround line 85 of the ui.tabs.js
// For dynamically created HTML that contains a hash as href IE < 8 expands
// such href to the full page url with hash and then misinterprets tab as ajax.
// Same consideration applies for an added tab with a fragment identifier
// since a[href=#fragment-identifier] does unexpectedly not match.
// Thus normalize href attribute...
var hrefBase = href.split('#'), baseEl;
var onlyLocation= location.toString().split('#');
var locArray= onlyLocation.split('/');
var lastElement= locArray[locArray.length-1];
if (hrefBase && (hrefBase === location.toString().split('#') ||
(baseEl = $('base')) && hrefBase === baseEl.href) ||
(hrefBase.indexOf('/') == -1 && hrefBase == lastElement)
href = a.hash;
a.href = href;
Would be great if it could be included in a future version.
There is still one case not catched, when the href is "./MyPage.html", then it still goes wrong, but so far we did not have that case.
Attached is a diff