JoséCosta caso não queiras colocar plugin nenhum, coloca o seguinte código no functions.php do teu tema, fiz para um blog meu e desde daí é sempre certo. Especialmente quando as pessoas fazes Gosto não aparece mais nenhuma imagem ao calhas que esteja na página, mas sim a imagem do artigo.
/**
* thumbnail para Facebook Gosto e Partilhar - http://blog.ashfame.com/?p=888
*/
add_action( 'wp_head', 'fb_like_thumbnails' );
function fb_like_thumbnails()
{
global $posts;
$default = 'AQUI METES UMA URL PARA UMA IMAGEM POR DEFEITO, POR EXEMPLO A DO TEU LOGOTIPO';
$content = $posts[0]->post_content; // $posts is an array, fetch the first element
$output = preg_match_all( '/<img.+src=[\'"]([^\'"]+)[\'"].*>/i', $content, $matches);
if ( $output > 0 )
$thumb = $matches[1][0];
else
$thumb = $default;
echo "\n\n<!-- Facebook Thumbnail -->\n<link rel=\"image_src\" href=\"$thumb\" />\n<!-- Fim Facebook Thumbnail -->\n\n";
}
Tartofs caso utilizes o Wordpress Seoele faz isso tudo, e é menos um plugin que tens. OU então podes adicionar o seguinte código.
//Adding the Open Graph in the Language Attributes
function add_opengraph_doctype( $output ) {
return $output . ' xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"';
}
add_filter('language_attributes', 'add_opengraph_doctype');
//Lets add Open Graph Meta Info
function insert_fb_in_head() {
global $post;
if ( !is_singular()) //if it is not a post or a page
return;
echo '<meta property="fb:admins" content="ID da PÁGINA de FACE"/>';
echo '<meta property="og:title" content="' . get_the_title() . '"/>';
echo '<meta property="og:type" content="article"/>';
echo '<meta property="og:url" content="' . get_permalink() . '"/>';
echo '<meta property="og:site_name" content="NOME DO SITE" />';
if(!has_post_thumbnail( $post->ID )) { //the post does not have featured image, use a default image
$default_image="URL PARA IMAGEM"; //replace this with a default image on your server or an image in your media library
echo '<meta property="og:image" content="' . $default_image . '"/>';
}
else{
$thumbnail_src = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'medium' );
echo '<meta property="og:image" content="' . esc_attr( $thumbnail_src[0] ) . '"/>';
}
echo "\n";
}
add_action( 'wp_head', 'insert_fb_in_head', 5 );