ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Facebook and EE captchas

August 16, 2013 11:49am

Subscribe [2]
  • #1 / Aug 16, 2013 11:49am

    Alex Boese

    125 posts

    When people link to one of my site’s pages from facebook, facebook decides what image from that page to use as a thumbnail, and often, in its great wisdom, decides to use the captcha image. So I’ve been trying to come up with a way to stop it from doing this.

    The first thing I did was to use facebook’s “open graph” meta tags to point it at the proper images to use. But facebook happily ignores my meta-tag suggestions. Which makes me wonder why facebook urges people to use these meta tags if it’s just going to ignore them.

    But anyway. The next thing I’ve been trying is to come up with a way of hiding the captcha images from facebook.

    Apparently facebook pays attention to images that are coded like this:

    <a href="http://whatever.com">http://whatever.com/whatever.jpg</a>

    However, it ignores background images coded like this:

    <a href="http://whatever.com"></a>

    So does anyone know if there’s a way to get the captchas to display as background images, so facebook will ignore them?

  • #2 / Aug 16, 2013 11:59am

    Alex Boese

    125 posts

    Note: there should be a ‘style = background-image’ in the second bit of code above. but for some reason it was deleted when I hit post.

  • #3 / Aug 21, 2013 2:40pm

    Chriiiiso

    46 posts

    Hrm, the tags work for me.  What I use is a featured image field in expression engine, which I use if I’m displaying a link to that page in other places on the site, etc.  I let Facebook use that

    Then in the head’s meta tags, I use

    <meta property="og:image" c />

    So the entire metatag section for open graph looks something like this when rendered:

    <meta property="og:title" c Title" />
    <meta property="og:url" c />
    <meta property="og:type" c />
    <meta property="og:image" c />
    <meta property="og:description" c blah blah blah blah" />
    <meta property="og:site_name" c Name" />
    <meta property="fb:admins" c />

    edit:  sorry the forum is butchering the code so I can’t seem to help you.  But maybe re-reading the open graph documentation will help.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases