Display Google Street View instead of thumbnail on post preview
-
Hello,
I want to display small live google street view image instead of a post thumbnail.
Here is the code for displaying thumbnail:
<figure> <a href="<?php the_permalink(); ?>"> <?php global $post; if( has_post_thumbnail( $post->ID )) { // get_template_part('property-details/map-snippet'); the_post_thumbnail( 'property-thumb-image' ); } else { inspiry_image_placeholder( 'property-thumb-image' ); } ?> </a> <?php display_figcaption( $post->ID ); ?> </figure>
The google street view on my theme is called by get_template_part function and when Im trying to replace the part for thumbnail with this function it only shows up the street view on one out of four posts in the search results. Whatever I put there instead the thumbnail it works fine, displaying on all four posts, whereas street view not.
here is the snapshot As you can see it is not even in the proper place, showing address for the bottom right property. What do I do wrong here? Can someone help? Thanks
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Display Google Street View instead of thumbnail on post preview’ is closed to new replies.