Drupal views ajax complete


/ Published in: jQuery
Save to your folder(s)

Get the ajax complete event after filtering a view content in drupal


Copy this code and paste it in your HTML
  1. (function($) {
  2. Drupal.behaviors.events = {
  3. attach: function(context, settings) {
  4. $('#view-id', context).ajaxStart(function(){
  5. $('#views-exposed-form-events-page,div.view-id-events', context).fadeTo(300, 0.5);
  6. });
  7. $('#view-id', context).ajaxSuccess(function(){
  8. $('#views-exposed-form-events-page', context).fadeTo(300, 1.0);
  9. $('div.view-id-events', context).css('opacity', 0.5).fadeTo(300, 1.0);
  10. });
  11. }
  12. };
  13. })(jQuery);

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.