Recent Topics

Twitter chooses second pic?

Started by on Jan 31, 2017 – Contents updated: Feb 19, 2017

Jan 31, 2017 11:17    

Just a minor thing I observed.
When I post links from blog posts to Twitter (either via the plug-in ping or manually), the second picture of the post appears in the Twitter card. I didn't really care much until I posted an article with only 1 picture. The Twitter card does not fall back on the only available pic, but instead includes no pic.

Facebook doesn't seem to make up its mind whether to bother displaying any image when I include a link manually in a post. It usually doesn't.
Btw, LinkedIn uses the first image. So that's all good.

Any idea what's going on with Twitter and Facebook?

Using:
b2e: 6.8.2-stable released on 17/11/16
evo_twitter 6.7.9

Jan 31, 2017 18:54

We'll check but you should upgrade your b2evo as fast as possible. 6.8.2 has some serious security issues.

Feb 10, 2017 07:15

Hi @bluesteens

Could you please provide the url of the page and the related Twitter/Facebook post. A screenshot of the attachments list of the same post would also be helpful in debugging this issue.

Feb 13, 2017 02:56

Thanks for the screenshot. I see that in the article with two pictures, both images are in the inline position. The version you are using does not use inline images in generating Twitter summary cards, only images in the cover and teaser position are used. If you will view the page source of the first article you will not find a twitter:image meta tag in there and it is left to Twitter to select what image to display. The second article has an image in the teaser position and that will generate a twitter:image meta tag.

I have already pushed changes to the code to consider all attached images in any position but only the first image will be used based on the following sorting criteria:

cover (first priority) > teaser-* (second priority) > other positions (last priority)

If two or more images are in the same priority position, the link order (in the attachment list window) is used to select the image. Hopefully, the changes I made will be available on the next upgrade.

I am still not sure why no pics are shown in the posts on Facebook. I tried your links in the sharing debugging tool (https://developers.facebook.com/tools/debug) and it seems to correctly identify all the meta tags.

This post has 2 feedbacks awaiting moderation...


Form is loading...

powered by b2evolution – This forum is powered by b2evolution CMS, a complete engine for your website.