Hi Jason
Great to speak with you. So, you are going to contact the OP from this thread:
https://support.searchandfilter.com/forums/topic/trying-to-implement-with-animations-and-masonry/
And see if he can give you a bit of guidance. Let me know how you get on. If you manage to resolve it, also let me know if I can close the thread?
AnonymousInactive
I’m trying to implement our search pages with masonry and related animations. What I’m wondering is whether there’s some javascript event that happens when a search submission happens (using the ajax version of your form).
Here’s a working version of the animation I’m trying to get to:
http://johnperezgraphics.flywheelsites.com/testimonials/
I’ve implemented the “news” page of the site to where on the initial load it works in the same way, but can’t seem to figure out how I could get the masonry to refire, so to speak, when new results are loaded.
http://johnperezgraphics.flywheelsites.com/category/news/
How did you call the masonry file into the page before?
What I meant was to put the code that you need from the FAQ page of ours into a file called ….
And the call that from the functions file to load it to the page.
Call me on Skype (make it quick as I have to go out).
Great to speak with you Jason. I need to get back to you with a method to re-initialize masonry.js after the form has been submitted with Ajax. Right now you have to make a selection watch it change, then refresh the page!!
Hi Jeremy
Great to talk with you. So, my thoughts were:
#1 Add Enhanced Media Library plugin, so the media has tags and categories.
#2 Discover a method to import media into WP that translates the client’s work of entering keywords on media files and use those keywords as tags.
#3 Explore EML plugin to bulk import media into a category, where that category is the collection name
#4 Create pages to show specific categories in a media masonry grid, where the S&F form can search/filter by media tags making use of the page url to establish the category.
AnonymousInactive
Hello,
I am having issues with where to insert the shortcode in my existing theme. I have inserted it where I want however the show = results shortcode changes they the way the blog posts are displayed. My posts are displayed in a masonry layout and when the shortcode is entered the display changes to like a full blog post theme. Is there a way to incorporate the shortcode without it modifying my existing theme?
Also, I would like some assistance with inserting the appropriate code so that the search and filter check boxes are displayed horizontally.
Thank you,
Alex
AnonymousInactive
Hi Trevor,
thanks to your excellent guidance and explanations.
The results.php is working now as intended.
check out: https://www.kleinkunst.theater/
Pls note that I have translated some words into german.
(not yet internationalised code, but will add that as well)
<?php
/**
* Search & Filter Pro
*
* Sample Results Template
*
* @package Search_Filter
* @author Ross Morsali
* @link http://www.designsandcode.com/
* @copyright 2015 Designs & Code
*
* Note: these templates are not full page templates, rather
* just an encaspulation of the your results loop which should
* be inserted in to other pages by using a shortcode - think
* of it as a template part
*
* This template is an absolute base example showing you what
* you can do, for more customisation see the WordPress docs
* and using template tags -
*
* http://codex.wordpress.org/Template_Tags
*
*/
if ( $query->have_posts() )
{
?>
<?php echo $query->found_posts; ?> Beiträge gefunden<br />
Seite <?php echo $query->query['paged']; ?> von <?php echo $query->max_num_pages; ?><br />
<div class="pagination">
<div class="nav-previous"><?php next_posts_link( 'Ältere Beiträge', $query->max_num_pages ); ?></div>
<div class="nav-next"><?php previous_posts_link( 'Neuere Beiträge' ); ?></div>
<?php
/* example code for using the wp_pagenavi plugin */
if (function_exists('wp_pagenavi'))
{
echo "<br />";
wp_pagenavi( array( 'query' => $query ) );
}
?>
</div>
<div class="row row-masonry">
<?php
while ($query->have_posts())
{
$query->the_post();
?>
<article <?php post_class('post-masonry col-sm-' . $grid_col); ?>>
<div class="post-inner">
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
<?php echo at_post_thumbnail($post->ID, 'at_thumbnail', $args); ?>
</a>
<h2>
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
<?php the_title(); ?>
</a>
</h2>
<p><?php echo the_excerpt(); ?></p>
<div class="clearfix"></div>
</div>
</article>
<?php
}
?>
</div>
Seite <?php echo $query->query['paged']; ?> von <?php echo $query->max_num_pages; ?><br />
<div class="pagination">
<div class="nav-previous"><?php next_posts_link( 'Ältere Beiträge', $query->max_num_pages ); ?></div>
<div class="nav-next"><?php previous_posts_link( 'Neuere Beiträge' ); ?></div>
<?php
/* example code for using the wp_pagenavi plugin */
if (function_exists('wp_pagenavi'))
{
echo "<br />";
wp_pagenavi( array( 'query' => $query ) );
}
?>
</div>
<?php
}
else
{
echo "No Results Found";
}
?>
AnonymousInactive
Hey Ross, just had chance to test a little more, basically I’ve now re-added masonry and set it to go to “Results Container” and it actually works fine on Firefox and Internet Explorer.
But it doesn’t work on Chrome (tested on different machines too just in case) or on Safari (tested on mobile, where it just stays at the bottom of the results) – they just won’t play ball. It’s as though they just can’t see the container, but it’s there, and there’s no code/tag snags that could confuse it, and it’s a unique identifier, you can see if you view source. I also added a completely separate dummy container, and set it to go to “Custom Selector:” but sadly it made no difference.
Any ideas? As mentioned I don’t want to place that other code you suggested, as I want this to work on another set of results without masonry so need it for that anyway. Many thanks 🙂
AnonymousInactive
Hey Ross,
I know, so strange! So I’ve changed it to custom and set it to go to #focus-results but still not working.
No, I haven’t tried your other suggestion yet, only because I want this to work for another search form on a people search where there will be no masonry so would like to try and get this one sorted first if that’s ok, then you never know it may just work again on masonry too, but if not I will try what you have said for sure :).
AnonymousInactive
Hi Ross,
Ahaa! I just removed masonry and it’s still not working – so a good question raised thank you.
You can re-check that page now and see what I mean. Do you know why that’s not working?
Many thanks,
TJ