Sharing links with thumbnails using custom field.
-
// facebook connect digg social media image function get_social_img() { global $post; if ( is_single ()){ $image = get_post_meta($post->ID, 'your_custom_field_name', $single = true); ?> <link rel="image_src" href="<?php echo $image; ?>" /> <? } } add_action('wp_head', 'get_social_img');
I have used this and placed on my functions.php it worked for some but there are some that didn’t showed thumbnails is there some updating required to have all my post show thumbnails on facebook can somebody check this is my site: https://www.flippish.com.
- The topic ‘Sharing links with thumbnails using custom field.’ is closed to new replies.