nothing i found how to do it
Plugin Author
WPSOLR
(@wpsolr)
I’m sure others would be interested.
Could you explain how you managed to do it ?
inside file class-wp-solr.php after this peace of code that start at line number 383:
foreach ( $resultset as $document ) {
$id = $document->id;
$pid = $document->PID;
$name = $document->title;
$content = $document->content;
i added this:
// MY added
$image_url = wp_get_attachment_image_src( get_post_thumbnail_id($id));
and then where is generated list of articles afert line with this code:
$msg .= “<div id=’res$i’><div class=’p_title’ style=’clear:both;’>$name</div>”;
i added:
// MY added
$msg .=”<img class=’result_list_thumb’ src=’$image_url[0]’ />”;
that’s all.
Plugin Author
WPSOLR
(@wpsolr)
@mstancikova, thanks for your feedback to the community. I will check how to integrate your suggestions to the plugin.
We are also planning to change the very principle of how to display Solr search results, Solr facets, and Solr autocomplete drop down, by intercepting actions and filters of the active theme’s search.
Which means that your own theme will be able to define the whole search UIs.
Plugin Author
WPSOLR
(@wpsolr)
The latest 1.9 version displays thumbnails.