fixed preloader

v1.18.x
psychobunny 11 years ago
parent fee591e551
commit 71214c6255

@ -181,7 +181,7 @@ var ajaxify = ajaxify || {};
ajaxify.loadData = function(url, callback) {
$(window).trigger('action:ajaxify.loadingData', {url: url});
if (ajaxify.preloader && ajaxify.preloader.url === url) {
if (ajaxify.preloader && ajaxify.preloader.url.replace(/[\?|\&]prefetched=true/, '') === url) {
return callback(null, ajaxify.preloader.data);
}
@ -293,7 +293,6 @@ var ajaxify = ajaxify || {};
// Internal link
var url = this.href.replace(rootUrl + '/', '');
url = url + (url.match(/\?/) ? '&' : '?') + 'prefetched=true';
console.log(url);
ajaxify.loadData(url, function(err, data) {
ajaxify.preloader = {

Loading…
Cancel
Save