Support » Plugin: Yoast SEO » og:image tag stripped out when I set a page to be homepage

  • Resolved kylong

    (@kylong)


    The og:image tag is being stripped out of the source code when I set a page to be the homepage.
    **Steps to replicate**
    1. Make a page.
    2. Set a featured image.
    3. In Yoast set a social media Facebook image.
    4. Publish. The featured image is present when the page is shared to Facebook. The og:image tag is in the source code.
    5. In ‘Settings/Reading” set the page you’ve made to be the static homepage.
    6. Check the source code. The og:image tag is gone. The page shares to facebook with the wrong image (ie first image listed in the code)

    Any ideas? Thanks.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter kylong

    (@kylong)

    ps I have tried the fix proposed on GitHub (listed below.)
    This does not fix the problem.

    **Git Hub proposed fix**
    Test instructions
    This PR can be tested by following these steps:

    Go to SEO → Social → Facebook and select a default image (let’s call it Image A)
    Set your homepage to a static page
    Edit the homepage and select a different og:image (Image B) through Yoast SEO
    Check the homepage’s source, the og:image now displays the set image for the frontpage.

    Hello!

    I’m having the same issue. The og:image properties are missing from the homepage, even if I add a Facebook image inside Yoast’s social box.

    Adding the above fix does make the og:image properties to appear on the homepage, but the default image shows, the one set in SEO -> Social -> Facebook, not the one set in the homepage itself.

    Thread Starter kylong

    (@kylong)

    Thanks. Hardly a workable solution for a regularly publishing blog though! Looking forward to the real fix real soon.

    • This reply was modified 5 years, 9 months ago by kylong.
    Plugin Support Jerlyn

    (@jerparx)

    We apologize for the inconvenience. There’s currently an open issue with our developers regarding featured image is not outputted as og:image on static homepage. You can check the GH issue here: https://github.com/Yoast/wordpress-seo/issues/9730

    The fix will be included on Yoast SEO 7.8 which is set to be released this July.

    Thread Starter kylong

    (@kylong)

    Thanks for the update. Will let clients know estimated fix date. Cheers

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘og:image tag stripped out when I set a page to be homepage’ is closed to new replies.