Add Meta Tags
[resolved] Image Size for Schema and OG (5 posts)

  1. Eric Prindle
    Posted 2 years ago #

    When I post a link from my blog to Facebook and Google+, only a small thumbnail image displays rather than an image that fills the full width of the post. This appears to be because AMT selects the "medium" version of each image (normally 300 pixels in width) for the og:image and schema ImageObject tags. Reportedly, the minimum width for Facebook to display a full-width image is 560, while the minimum width for Google+ is 506. Is there a way to reference the full-size version of at least the featured image in the og and schema tags?


  2. superkaratemonkeydeathcar
    Posted 2 years ago #

    Hi Eric,
    I was having the same issue myself.

    So I poked around in the plugin files, found a solution & thought I'd share.

    Beforehand though,
    NOTE: This type of Trial+Error also works best if you have a little separate testing-area install of WP on a subdirectory of your server like /newfeaturetests/ or whatever.
    -So you don't screw an important live-site horking around with your core php files, by making some little syntactical or punctuation mistake.
    Just fill it with dummy headers, entries, images, etc. and fool around with no/low consequences.


    If you go into Plugins>Editor, and look in the files:

    On Line 510 of the OpenGraph one you should see:
    Change medium to the image size that you would like. In mine, I just put full, because mine aren't that big.
    Also, Put a note in the nearest comment area of the php file that you changed something to remind yourself what, when & where.
    Save the changes with "Update File".

    In the file for the Twitter Cards its on Line 137.

    I haven't looked in the Schema one, but a search for the word, 'medium' and then a change to your desired size should give similar results. (upd: It might be the one on Line 410)

    Do the same thing, super-reload the page & see what happens.

    Best of Luck; Cheers.

  3. George Notaras
    Plugin Author

    Posted 1 year ago #

  4. George Notaras
    Plugin Author

    Posted 1 year ago #

    Fixed in 2.5.0 which will be out soon.

    Customization of the image size via filters will be possible.

    Thanks for your feedback.

  5. George Notaras
    Plugin Author

    Posted 1 year ago #

    Please, check out 'Example 5' in the plugin description page for sample code in order to customize the image size used in meta tags.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Add Meta Tags
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic