How does Facebook Sharer select Images and other metadata when sharing my URL?

前端 未结 12 2044
忘掉有多难
忘掉有多难 2020-11-21 04:20

When using Facebook Sharer, Facebook will offer the user the option of using 1 of a few images pulled from the source as a preview for their link. How are these images selec

12条回答
  •  终归单人心
    2020-11-21 05:07

    I couldn't get Facebook to pick the right image from a specific post, so I did what's outlined on this page:

    https://webapps.stackexchange.com/questions/18468/adding-meta-tags-to-individual-blogger-posts

    In other words, something like this:

    
      
     
    

    Basically, you're going to hard code an if statement into your site's HTML to get it to change the meta content for whatever you've changed for that one post. It's a messy solution, but it works.

提交回复
热议问题