og:image does not parse url from image field properly when there is a comma in the alt field

Created on 7 July 2016, over 8 years ago
Updated 24 January 2023, almost 2 years ago

Let's say my ALT tag is "Here's me in Paris, France". This is what I would get:

<meta property="og:image" content="http://www.example.com/sites/default/files/MY_IMAGE.jpg, France" typeof="foaf:Image" class="img-responsive" />

Note the offending ", France" followed by the other <img> properties that should not be included.

The weird thing is that the image_src tag parses the url correctly.

For now I'm just avoiding using commas in the ALT tag, though that obviously isn't a long-term solution.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Open Graph

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024