Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #430847

    Hi, is there a way to show the featured images of the posts shown in the search results page?

    #431410

    Hey DROR!

    You can refer to this link: https://kriesi.at/support/topic/add-featured-image-to-search-results/#post-249161

    Regards,
    Yigit

    #431540
    This reply has been marked as private.
    #431812

    Hi!

    Use this in the Quick CSS field:

    span.search-result-counter, span.search-result-counter img {
      width: 100%;
      height: auto;
      position: relative;
      border-radius: 0;
    }

    Best regards,
    Ismael

    #431816
    This reply has been marked as private.
    #431821

    Also, how can I make the images link to the post? As they are now, they aren’t linking to the post and only the post title is the link.

    #432575

    Hi!

    Replace the code with this to create a link:

     $searchthumb    = get_the_post_thumbnail( $post_id, $size, $attr );
                    echo "<span class='search-result-counter {$counterclass}'><a title='".the_title_attribute('echo=0')."' href='".get_permalink()."' $markup>{$searchthumb}</a></span>";

    Add this in the Quick CSS field to align the search result:

    #top .template-search.content .entry-content-wrapper {
      padding-left: 0;
    }

    Best regards,
    Ismael

    #432623

    Great stuff :)

    Final thing, how can I make the post titles bigger in the search results without effecting any other title across the site?

    Thanks

    #432625
    This reply has been marked as private.
    #433263

    Hi!

    Use this to make the font size bigger:

    .template-search .entry-content-wrapper .post-title {
      font-size: 25px;
    }

    There is no special script to keep the images from loading automatically. I think it’s just a delay.

    Cheers!
    Ismael

    #433519

    OK, thanks.

    Is there a way to make the search results page full width (no sidebar) and to have it display the results in a masonry gallery with the title showing always and once hovering it will also show the excerpt?

    #434203

    Hi!

    Please add following code to Quick CSS

    .search-results .sidebar { display: none !important; }
    .search-results .content { width: 100%!important; border: none !important; }

    It is currently not possible to display search results in masonry. If you really need it, please hire a freelance developer

    Best regards,
    Yigit

    #434236

    OK, thanks :)

Viewing 13 posts - 1 through 13 (of 13 total)
  • The topic ‘How to show post images in the search results’ is closed to new replies.