Facebook Open graph tags for blogger - OG Image is too small. Can I designate full size image instead of thumbnail?

后端 未结 1 1640
无人及你
无人及你 2021-01-19 16:53

Blogger does not allow you to designate an open graph image in each post. Currently, there is a piece of code in the template that designates the automatically generated thu

1条回答
  •  离开以前
    2021-01-19 17:03

    I know this is an old question (2 years ago), but I hope my answer can help other peoples when they are looking for a solution.

    Currently, we are using this code to create thumbnail when sharing links on Facebook:

    And Blogspot will generate the HTML code looks like this:

    Yes, as you said, it is a 72x72 image. But did you know that we can change the image size based on the image URL?

    When you replace s72-c to w600-h315-c (600x315):

    Now, the problem is how we can replace the new link? I used the following tricks:

    And here is the simple PHP code:

    The final result:

    Read my blog post for more details.

    0 讨论(0)
提交回复
热议问题