MINOR Only use cookie storage in TabSet.js if the element has a unique ID to correlate the cookie to

This commit is contained in:
Ingo Schommer 2012-01-07 18:57:40 +01:00
parent ef514b924e
commit 7e347217a6

View File

@ -18,9 +18,10 @@
this.rewriteHashlinks(); this.rewriteHashlinks();
// Initialize jQuery UI tabs // Initialize jQuery UI tabs
var id = this.attr('id');
this.tabs({ this.tabs({
cookie: $.cookie ? { expires: 30, path: '/', name: 'ui-tabs-' + this.attr('id') } : false cookie: ($.cookie && id) ? { expires: 30, path: '/', name: 'ui-tabs-' + id } : false
}); });
}, },
/** /**