Did AJAX At Work Now?
Original >>
I think it's very simple and useful short script. Jquery + CakePHP or any PHP page.
It's a AJAX Global Activity code:
$(function() {
var $headline = $('h1:first');
$(document).ajaxSend(function() {
$headline
.removeClass('activity')
.addClass('activity');
});
$(document).ajaxStop(function() {
$headline.removeClass('activity')
});
});
So. When ANY AJAX activity - your 'activity'-class will be work;-) Easy ;-)
I think it's very simple and useful short script. Jquery + CakePHP or any PHP page.
It's a AJAX Global Activity code:
$(function() {
var $headline = $('h1:first');
$(document).ajaxSend(function() {
$headline
.removeClass('activity')
.addClass('activity');
});
$(document).ajaxStop(function() {
$headline.removeClass('activity')
});
});
So. When ANY AJAX activity - your 'activity'-class will be work;-) Easy ;-)