Permalink
Browse files

MERGE tabs url abs

  • Loading branch information...
chillu committed Apr 18, 2012
1 parent f26951c commit 3ee44594765b2692d0787f16820aba10ad0647c4
Showing with 5 additions and 1 deletion.
  1. +5 −1 admin/javascript/LeftAndMain.js
@@ -638,7 +638,11 @@ jQuery.noConflict();
ajaxOptions: {
// Overwrite ajax loading to use CMS logic instead
beforeSend: function(xhr, settings) {
- $('.cms-container').entwine('ss').loadPanel(settings.url);
+ var makeAbs = $.path.makeUrlAbsolute,
+ baseUrl = $('base').attr('href'),
+ isSame = (makeAbs(settings.url, baseUrl) == makeAbs(document.location.href));
+
+ if(!isSame) $('.cms-container').entwine('ss').loadPanel(settings.url);
return false;
}
},

0 comments on commit 3ee4459

Please sign in to comment.