Jump to content

Need help with og:image source code


Dirty Butter

Recommended Posts

I need help making Facebook happy with my Open Graph image setting.

I've tried using this:

<link rel="image_src" href="{$PRODUCT.large}" />
<meta property="og:image" content="{STORE_URL}/images/cache/{$PRODUCT.large}"/>

I thought this would work in the element.meta.php file, but it didn't.

This would probably have been much easier before I put almost all our images in folders. That's one action I have really wished I had never done - but it's that way now.

I would prefer using the source file url, but that would be a different folder for different listings.

I've tried

<meta property="og:image" content="{$image.source}"/>

But that did not work, either.

I've managed to work out all the other Open Graph settings Facebook requires, but I'm stumped on the image.

Has anyone made this work for Facebook ?

Link to comment
Share on other sites

What does Facebook require?

On the Product front page, this has the actual full URL: {$PRODUCT.source}

(I believe so - I may have added this code to this development branch that I am looking at to answer this question.)

And what is wrong with the existing code in element.meta.php?

Link to comment
Share on other sites

It needs to be code that picks up the image url for each product, not inferred from other code on the page. I'm trying to cross the t's and dot my i's, because I'm having trouble getting Facebook to approve of an App.

I'm not sure you will see what I see from this url:

Quote

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...