Display custom pin it button inside the WordPress Loop

Here is how I solved my problem.

Just drop this inside the WordPress loop and it should do the trick.

<a href="//pinterest.com/pin/create/button/?url=<?php the_permalink(); ?>&media=< ?php $thumb = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), 'thumbnail' ); echo $thumb['0']; ?>" data-pin-do="buttonPin" data-pin-config="none"><img src="//assets.pinterest.com/images/pidgets/pin_it_button.png" /></a>
Comments ( 0 )

    Leave A Comment

    Your email address will not be published. Required fields are marked *