Customizing Search Results page to show the excerpt
-
How can I customize the search results page to display the excerpt only?
I like the Shop Isle theme, but either it is too complicated/layered or do versions of WordPress themes since 2016 require an additional level of abstraction?
WHAT I TRIED ALREADY:
I checked search.php, which seemed like an intutive place to keep the code for search results. But, the code was not there. Instead it led me to another file called content.php, but the code to edit wasn’t in that file either. I even wrote a blog post about my struggle here: https://erichepperle.com/developer-journal-wp-shop-isle-search-excerpts/
This is all it says in content.php:
<div <?php post_class( 'post' ); ?> id="post-<?php the_ID(); ?>"> <?php /* * @hooked shop_isle_post_header() - 10 * @hooked shop_isle_post_meta() - 20 * @hooked shop_isle_post_content() - 30 */ do_action( 'shop_isle_loop_post' ); ?> </div><!-- #post-## -->
It seems that “@hooked shop_isle_post_content()” or “shop_isle_loop_post” are the important lines of code. But neither of these correlate with a php filename.
I’m stumped. Any help is appreciated.
The page I need help with: [log in to see the link]
- The topic ‘Customizing Search Results page to show the excerpt’ is closed to new replies.