HI JLeuze,
Same as these threads I'm having an issue with your great plugin Meteor Slides and this code
add_filter( 'post_thumbnail_html', 'my_post_image_html', 10, 3 );
function my_post_image_html( $html, $post_id, $post_image_id ) {
$html = '<a href="' . get_permalink( $post_id ) . '" title="' . esc_attr( get_post_field( 'post_title', $post_id ) ) . '">' . $html . '</a>';
return $html;
};
Now the solutions given in those threads don't seem to work for me, since I'm using both Meteor Slides and those thumbnails in a custom page, out of the_loop.
To have the thumbnails shown, I'm using this piece of code
<?php if ( is_front_page() ) { ?>
<?php $query = new WP_Query(array('cat'=> '5', 'posts_per_page'=> '10', 'orderby'=>'rand'));
while ($query->have_posts()) : $query->the_post();
the_post_thumbnail ('thumbnail');
endwhile; ?>
<?php } ?>
And this code does not allow me to include a workaround like
<a href="<?php the_permalink(); ?>"><?php the_post_thumbnail(); ?></a>
Do you have any other ideas how i could use both Meteor Slides and the clickable thumbnails on one custom page out of the_loop?
Thanks in advance!