-
AuthorSearch Results
-
January 19, 2017 at 12:01 pm #83677
In reply to: How display Result page as Grid ?
TrevorParticipantI have written a new results.php for you:
<?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() ) { ?> Found <?php echo $query->found_posts; ?> Results<br /> Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?><br /> <div class="pagination"> <div class="nav-previous"><?php next_posts_link( 'Older posts', $query->max_num_pages ); ?></div> <div class="nav-next"><?php previous_posts_link( 'Newer posts' ); ?></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="col-9 hb-equal-col-height hb-main-content"> <div id="hb-blog-posts" class="hb-blog-grid masonry-holder clearfix" data-layout-mode="fitRows" data-categories="" data-column-size="col-4"> <?php while ($query->have_posts()) { $query->the_post(); ?> <article id="post-<?php echo get_the_ID();?>" class="col-4 post-<?php echo get_the_ID();?> post type-post status-publish format-standard has-post-thumbnail hentry" itemscope="" itemtype="http://schema.org/BlogPosting"> <div class="featured-image"> <a href="<?php the_permalink(); ?>"> <?php if ( has_post_thumbnail() ) { the_post_thumbnail("small"); ?> <div class="featured-overlay"></div> <div class="item-overlay-text" style="opacity: 0;"> <div class="item-overlay-text-wrap" style="padding-top: 0px;"> <span class="plus-sign"></span> </div> </div> <?php } ?> </a> </div> <div class="post-content"> <div class="post-header"> <h2 class="title" itemprop="headline"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2> </div> <p><?php echo get_the_excerpt(); ?> <br /><a href="<?php the_permalink(); ?>" class="read-more">Read More</a> </p> </div> </article> <?php } ?> </div> </div> Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?><br /> <div class="pagination"> <div class="nav-previous"><?php next_posts_link( 'Older posts', $query->max_num_pages ); ?></div> <div class="nav-next"><?php previous_posts_link( 'Newer posts' ); ?></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"; } ?>
January 16, 2017 at 9:30 am #82551In reply to: How do I alter what the results look like?
TrevorParticipantHi Nathan
Have you made a customizable version of the results.php file, as shown in the documentation?
This can be edited to any HTML structure that you want, and the code to show the thumbnail uses standard code from the WordPress codex, so you can change the size of the image to what you need using the standard size names (like
thumb
for thumbnail).January 14, 2017 at 3:20 pm #82390In reply to: Keyword Search Returning No Results
AnonymousInactiveHi Trevor,
We were using an edited results.php, but I already tried replacing it with the results.php from the newest version of the plugin to rule that out as a cause.
In order to help you troubleshoot, the results.php that is now on our page is an unedited version.
Thanks,
Ben
January 14, 2017 at 9:51 am #82350In reply to: Keyword Search Returning No Results
TrevorParticipantYou appear to be using the shortcode results method. Have you edited the results.php template that this method uses, and if so, can you post the contents of that file here, inside ‘code’ tags (the button for this is in the editor toolbar).
January 12, 2017 at 3:06 pm #81758In reply to: Search and filter reading from the Avada theme
TrevorParticipantYou are working on a customized version of the results.php and before making changes the pagination worked, but now it does not? If this is so, can you posts here, inside code tags (in the editor toolbar) the complete results.php file?
January 11, 2017 at 5:38 pm #81418In reply to: How to replicate some features of your demos
AnonymousInactiveHi Trevor,
thank you for you reply.
I have chosen the Shortcode results method. Therefore, I have looked at the link you suggested.
I have followed the instructions and created the results.php. Then I have deleted the part in the code showing the message of the number of results.
As a first and quick step, to me it’s ok.About point 2 in my original question:
a) is having the results displayed in a grid achievable with the Shortcode results method?
b) is there some quick combination with a plugin like Essential grid (that I have installed) or else?Regards
January 6, 2017 at 2:50 pm #80545In reply to: Issue: S&F displays all items
AnonymousInactiveI checked my theme folder and no results.php is there (both parent and child themes). Should it be there?
January 6, 2017 at 2:11 pm #80534In reply to: Issue: S&F displays all items
TrevorParticipantOK, thanks for trying that. Can you confirm that the results.php template that S&F uses on your setup is unedited/unchanged?
January 5, 2017 at 10:02 am #80197
TrevorParticipantFrom what I can see, you have made some changes to the results.php file. Can you paste the contents of the file here inside code tags?
January 5, 2017 at 9:52 am #80195In reply to: ACF Issues
TrevorParticipantHi Martyn
The easiest way to do this (doesn’t take me too long to od, so i can help you need it) is to take a page in your theme that looks the way you want and then edit our results.php file to have the same HTML structure to clone the look.
Starting this customisation process is described here.
-
AuthorSearch Results