使用共享URL的图像参数显示facebook共享图像的问题

问题描述:

我使用的是Facebook共享url,但无法显示url的图像参数,任何人都可以告诉我哪里可能会出错?使用共享URL的图像参数显示facebook共享图像的问题

HTML

<a title="Share this on Facebook" 
     href="http://www.facebook.com/sharer.php? 
     s=100 
&p[url]='http://www.test.com' 
     &p[images][0]='http://www.meandmrsjoneshotel.com/wp-content/themes/child-theme/img/fb-thumbs/home.png' 
     &p[title]='This is the title' 
     &p[summary]='This is the share description'" 
     target="_blank" class="fb ir"> 
     Share this page on Facebook 
     </a>​ 

JS小提琴http://jsfiddle.net/pUMZb/

感谢

+0

请使用Like按钮插件(https://developers.facebook.com/docs/reference/plugins/like/)共享有道,据我所知sharer.php有已退休。 – deesarus

尝试删除撇号。你的代码应该是这样的

<a title="Share this on Facebook" 
     href="http://www.facebook.com/sharer.php? 
     s=100 
&p[url]='http://www.test.com' 
     &p[images][0]=http://www.meandmrsjoneshotel.com/wp-content/themes/child-theme/img/fb-thumbs/home.png 
     &p[title]='This is the title' 
     &p[summary]='This is the share description'" 
     target="_blank" class="fb ir"> 
     Share this page on Facebook 
     </a>​