Support » Plugin: Facebook » [Plugin: Facebook] Open Graph Tags Conflict

  • Resolved jgbeldock


    It appears that the Facebook plugin automatically generates OG tags. Unfortunately, there seems to be a conflict between what those contain and what the app tells me to use. Is there a way to turn off the automatic generation by the Facebook plugin so I can control the content (i.e., write my own tags as part of my theme)?

    Here’s what the Facebook plugin automatically generates:

    <meta property="" content="en_US" />
    <meta property="" content="[blah]" />
    <meta property="" content="website" />  <strong>note, *NOT* what FB recommends!</strong>
    <meta property="" content="[blah]" />
    <meta property="" content="[blah]" />
    <meta property="" content="[somenumber]" />

    And here’s what the website tells me to use, which makes sense, because I am creating an APP, as the instructions for their plugin specifically tells me to do:

    <head prefix="og: fb: article:">
      <meta property="fb:app_id"      content="[somenumber" />
      <meta property="og:type"        content="article" /> <strong>This makes more sense </strong>
      <meta property="og:url"         content="Put your own URL to the object here" />
      <meta property="og:title"       content="Your Open Graph object title" />
      <meta property="og:image"       content="" />
      <meta property="og:description" content="Your Open Graph object description" />

    Anyone know how to turn off the automatic generation so I can implement what they tell me I should?


Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Niall Kennedy


    Facebook recommends mapping a prefix to a URI at a parent element (head) and simply referencing that prefix later in the document. Declaring an RDFa CURIE in this way is cleaner: og: + og:url instead of

    Not all themes may provide access to parents of the <meta> element: <head> or <html>. Given that unknown it’s better to declare the full property than reference an undeclared prefix.

    The Open Graph protocol defines “website” as its default type. The “article” type is another option in the global namespace. You could also declare your own under your application. A type of “website” could make sense for a site homepage; a type of “article” could make sense for an individual post with extra article properties declared for indexing such as publish date and author.

    You can always tap into the fb_meta_tags filter and override the defaults set by the Facebook plugin for a given query type.

    Thanks for clarifying that Niall. It seems odd that this cleaner method is not documented by Facebook which is probably why I was wondering the same thing.

    Niall, thank you. That makes a lot of sense. I wasn’t aware of the existence of the fb_meta_tags filter, but now I am. 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Plugin: Facebook] Open Graph Tags Conflict’ is closed to new replies.