Closed nutsandbolts closed 5 years ago
The official Open Graph protocol does not specify anything for a name
attribute.
However, Andrea's experience as well as this SO post suggest adding the custom name
attribute.
This issue has been annotated and is ready for testing.
I have the meta tag, but no single quotes around it as described..
It shouldn't be missing any quotes... We enclose the attributes in single quotes. Here is what it looks like in my development environment.
Are there any other meta tag plugins on the site, or is there another place we can see this happening?
This is the corresponding code that generates the meta tags.
Tested on another site and it was the same way - no single-quotes.. It turns out W3TotalCache strips them out in its minification.. Tested the tags and they work, so it looks like all is well.
I just changed the type of quotation back from single quotes to double quotes, hoping this prevents W3 Total Cache from stripping anything out.
How to test
og:image
. The corresponding<meta>
tag should include the attributename='image'
. # original issueLinkedIn prioritizes oEmbed data over OG tags when deciding what image to use in shares. For any customer with a plugin like Yoast or All in One SEO, oEmbed info in the page will result in a wrong image nearly 100% of the time.
According to LinkedIn's documentation and post inspector we can get around this by adding
name:"image"
as shown here:<meta name="image" property="og:image" content="[Image URL here]">