I have this jquery which runs and reloads all pages on my site at the moment. Problem is that I would prefer if the script does not reload certain pages.
For example: if urls contains "string-1" and/or "string-2" don't reload page. (where the strings are folders /blog/ for example). Is that possible? Thanks
$(function(){
$('body').fadeIn(1000);
if (localStorage.reloaded !== 'true') {
setTimeout(function(){
$('body').fadeOut(2000, function(){
localStorage.reloaded = 'true';
location.reload(true);
});
}, 5000); // 5 seconds for demo
}
});