• Resolved jamminjames

    (@jamminjames)


    When sharing a post on Twitter, it no longer adds the SEO Title, but the regular title.

    Other shares (Facebook, etc) are using the SEO Title.

    For example, this post, https://www.humortimes.com/57762/trump-announces-doctor-tour/, when shared on via the Facebook or other buttons, returns the title, author, “Humor Times” and the url, as it is set up in Yoast SEO. This results in: “Trump Announces ‘Doctor’ Tour – Rick Blum, Humor Times” and the url.

    However, for Twitter, it only gives the post title: “Trump Announces ‘Doctor’ Tour” and the url.

    It was working the proper way up until a couple months ago.

    The Yoast SEO folks assure me the problem is not on their end. Indeed, the og:title shows the whole line.

    Why isn’t Add to Any’s Twitter share using the og:title?

    What can be done to fix this? Thanks for any help.

    P.S. I tried entering this in Additional JavaScript (which shouldn’t be needed, I don’t think, since the og:title covers this):

    a2a_config.templates.twitter = “${title} – ${author}, Humor Times ${link} via @HumorTimes”;

    But the ${author} does not return the author. Is there something that will?

    • This topic was modified 8 years, 6 months ago by jamminjames.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author micropat

    (@micropat)

    Twitter only looks at og:title (etc.) for Twitter Cards, and AddToAny uses the WordPress title for Twitter and most other services because it’s a standard field in WordPress. There’s no WordPress standard for Open Graph fields, unfortunately, so there’s not much interoperability between various plugins and themes that implement and consume OG tags.

    Using JavaScript you can tap into AddToAny events to modify the shared title for Twitter, and you could append the author too. The ${author} placeholder isn’t implemented, but it’s a great idea that’s under consideration for a future plugin release.

    • This reply was modified 8 years, 6 months ago by micropat.
    Thread Starter jamminjames

    (@jamminjames)

    Hmm, I know I had it set up to work that way before, where Twitter shares included all that info. I do have Yoast SEO set up to produce Twitter Cards, could that have been it — could your plugin have picked that up somehow before, but not now?

    Yes, please do include ${author} asap! For sites like ours with multiple authors, that is important. Meanwhile, is there a way to use the javascript customization to pick up the og:title?

    • This reply was modified 8 years, 6 months ago by jamminjames.
    • This reply was modified 8 years, 6 months ago by jamminjames.
    • This reply was modified 8 years, 6 months ago by jamminjames.
    Thread Starter jamminjames

    (@jamminjames)

    Or, could I use my child functions file to create the {author} variable that my customized Twitter share could use?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Twitter button doesn’t give SEO title as it is set up’ is closed to new replies.