Forum Replies Created
-
AuthorPosts
-
Heidi
ParticipantSo I finally got around to trying to fix this again– I did reach out to FacetWP for support too and they suggested I contact WP Show Posts support. Is there a way to re-trigger the masonry layout dynamically?
Heidi
ParticipantAh ha! Thank you. That worked like a charm!
Heidi
ParticipantHere’s a few examples I got from them that have masonry specific
https://gist.facetwp.com/?_keywords=facetwp-loaded%20masonry
Wondering if that might help?
Heidi
ParticipantI’ve sent it via message– thanks for your help!
Heidi
ParticipantError is gone, but still not working….
Heidi
ParticipantI tried adding a priority of 100, but still not working. Same error. Addition things I can try? Grateful for any ideas…also happy to send you admin access if you want to try some things in real time.
Heidi
ParticipantI tried that, and I do see “loaded!”, but still not working. It does show an error “cannot call methods on masonry prior to initialization; attempted to call ‘layout'”
Here’s a screenshot of the full console:
https://couchfilmcollective.org/wp-content/uploads/Screen-Shot-2019-03-23-at-7.00.04-PM.pngHeidi
ParticipantNo luck, but could certainly be user error on my part. I’m putting the script in Elements– wp_footer and I’ve checked execute PHP, with a display rule of entire site. Is that correct?
Screenshot of Element:
https://couchfilmcollective.org/wp-content/uploads/Screen-Shot-2019-03-22-at-6.16.06-PM.pngScreenshot of a facet search with the masonry not quite working right:
https://couchfilmcollective.org/wp-content/uploads/Screen-Shot-2019-03-22-at-6.25.19-PM.pngAppreciate your help, Tom!
Heidi
ParticipantAccording to FacetWP help desk, masonry or other js scripts that need to reload can be done on the facetwp-loaded js hook
https://facetwp.com/documentation/developers/javascript/facetwp-loaded/However, I have no Javascript skills. I’ve tried this, but it doesn’t work:
<script> jQuery(document).on('facetwp-loaded', function() { jQuery( '.masonry-container' ).masonry( 'layout' ); }); </script>
Any better ideas? Much thanks!
Heidi
ParticipantA quick search on FacetWP shows that you are correct. I’ve asked them the question and also found some examples, but I am not sure which of these would apply best to WP Show Posts:
https://gist.facetwp.com/?_keywords=masonry -
AuthorPosts