Forums › Forums › Search & Filter Pro › Search & Filter with Post Grid Plugin
- This topic has 7 replies, 2 voices, and was last updated 9 years, 1 month ago by
Trevor.
-
Anonymous(Private) February 18, 2017 at 12:18 am #91016
Hi,
I’ve been trying to follow along with this discussion:
https://support.searchandfilter.com/forums/topic/create-a-search-form-like-the-demo-movie-reviews/…which led me to the Post Grid plugin that I’d like to use to display my results.
I tried adding this to my functions.php
function post_grid_filter_query_args_extra($query_args) { $extra_query = array ( 'search_filter_id' => 137, ); return array_merge($query_args, $extra_query); } add_filter('post_grid_filter_query_args','post_grid_filter_query_args_extra');…and then use the post grid code in my template:
<?php echo do_shortcode("[post_grid id='372']"); ?>But the filter doesn’t seem to link up correctly. I feel like I’m missing something or the code above is specific to that previous customers theme.
Any direction would be greatly appreciated.
ThanksAnonymous(Private) February 18, 2017 at 5:04 pm #91101HI Trevor, I was reading thoguh the documantation adn I didn’t have this code added to functions.php
add_filter('wp_title','search_form_title'); function search_form_title($title){ global $searchandfilter; if ( $searchandfilter->active_sfid() == 35889) { return 'Search Results'; } else { return $title; }If I add it the website stops loading.
-
AuthorPosts