Skip to content

Instantly share code, notes, and snippets.

@rmorse
Created March 23, 2017 18:27
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rmorse/3e0e2b812cf0523436b6e88697fbd0c6 to your computer and use it in GitHub Desktop.
Save rmorse/3e0e2b812cf0523436b6e88697fbd0c6 to your computer and use it in GitHub Desktop.
Search & Filter Pro - Divi Theme & Ajax - Blog Module (Grid)
//this code does the re-layout work needed when using S&F with the blog module, and when S&F Ajax is enabled
(function ( $ ) {
"use strict";
$(document).on("sf:ajaxfinish", ".searchandfilter", function(){
console.log("ajax complete");
var grids = document.getElementsByClassName('et_pb_blog_grid');
salvattore['register_grid'](grids[0]);
});
}(jQuery));
@rmorse
Copy link
Author

rmorse commented Dec 30, 2022

Update: this code is no longer required, this functionality has been added to our Divi integration plugin - https://searchandfilter.com/documentation/3rd-party/divi/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment