× Joomla Facebook Connect support forum

Topic-icon How to choose which picture in a story gets posted to Facebook?

Active Subscriptions:

None
When I like a story and it is posted to my Facebook, I do not see a mechanism to choose which picture in a particular story is posted. This is a problem for me for two reasons: 1) we have paid advertising, and the highest package includes being able to have visibility on our Facebook page. However, when I like a story, it often posts an advertisement as the picture on Facebook, regardless of whether or not they are supposed to have Facebook visibility. Problem 2) *a bigger problem* is that people have liked a story that my husband wrote on the economy that has a definite political slant. By pulling ads along with it, there is the perception that the particular advertiser is either in agreement with our political stance or that they themselves have posted the story since it's right next to a picture of their business. The story has a picture at the top, it's just not being posted. What am I doing wrong?
The topic has been locked.
Support Specialist
Jen,
Just so you know, I added the 6 month subscription that's in the jshenk account to your account as well, so you can post from either and access the extension easier.

1) You need to use Open Graph tags to set the image, title, description, or anything else you want control over when posted to Facebook. To do so, enable Open Graph integration in the Social -> Open Graph tab. Then, in your articles, add the following tags:
{JFBCGraph image=http://site.com/image-for-article.jpg}
{JFBCGraph title=Title for Facebook}
{JFBCGraph description=Description for facebook}

Once set, you can use the Linter tool to see how Facebook 'sees' your page. If you Like it right away, the changes may not take effect as it can take FB a day or so to update what it sees on it's own.
developers.facebook.com/tools/lint

2) See #1 :)

In the Open Graph section, there's also an option to pull the first image from an article. That option may work well for you too. You can also use it in conjuction with the Open Graph tags above.. if no explicit {JFBCGraph image=xxx} tag is set on the page, the first article will be used.

Hope that helps!
The topic has been locked.
Active Subscriptions:

None
Thanks for the quick and thorough response. We use iJoomla Magazine and iJoomla Ad Agency. I've noticed that when various people like a story, it takes the top ad up to Facebook, not just a random advertisement. Is there some way to allow the magazine or core Joomla to take precedence over the Ad Agency? Probably not, because that would be easy. I already had the Open Graph > First Image set to yes. My concern with your explanation is that I see it as a much more cumbersome process for me to publish stories. I currently don't have to go into the HTML at all, I just paste the text in and insert the picture. I don't add any tags to each story.

You say:
"In the Open Graph section, there's also an option to pull the first image from an article. That option may work well for you too. You can also use it in conjunction with the Open Graph tags above.. if no explicit {JFBCGraph image=xxx} tag is set on the page, the first article will be used."

This makes me think that based on the selection I've made to have it choose the first image, it should be the correct image that goes with the story, not the advertisements. What am I missing?
The topic has been locked.
Support Specialist
If the page is a standard Joomla article view, yes, it should be taking the first image in that article. If it's not, please let us know a page that you're seeing this 'bad' result on, so we can look at what's happening in the code. The only other thing I can think of is that AdAgency is possibly inserting the ad into the article itself. If so, then it would make sense that that's what we're detecting. If so, and they're using a Content Plugin, re-order it so it is ordered after the JFBConnect Content plugin.

Outside of standard Joomla articles which we should be pulling the first image for, we'd recommend another thing that may help you out from adding a tag for each article:
In the Open Graph configuration area of JFBConnect, add the following default tag. This will set the default image for any page of your site. It will be overridden if it's an article page and JFBConnect is automatically pulling the first image -or- if you specifically add a {JFBCGraph image=xx} tag:
image=http://site.com/liink-to-logo-or-other-generic-image.jpg

Hope that helps,
Alex
The topic has been locked.
Active Subscriptions:

None
Thank you. The vast majority of my stories are standard Joomla article view. I added the generic logo tag that you suggested I add to the Open Graph, but when I tested a couple (which I then removed the FB posts because it's 11pm and I want to freshly like those stories during reading hours), the results were inconsistent.

This link worked fine and pulled up the pictures of the antique dishes.
westminstervine.net/index.php/new-stories/1539-what-is-that-

This link brought up an advertisement
westminstervine.net/index.php/new-storie...host-golf-tournament

This one has been liked by a couple different people and the 'picture' they bring up varies, but it's always an advertisement.
The topic has been locked.
Support Specialist
Jen,
There are no Open Graph tags on the pages you linked. Can you double check that Open Graph integration is actually enabled in the Social configuration area? If it is, then can you try re-ordering the System plugin so it's at the very first position (lowest number). That may help, but definitely confused why they wouldn't be added. If you look at the page's HTML, you should og:title, og:image, og:description tags like:

meta property="og:title" content="SourceCoast Web Development"


Finally, when we do get the Open Graph tags setup, you can use the Linter tool to see what Facebook sees in your page. This tool is also useful to clear the Facebook's cache. Otherwise, right when you get the Open Graph tags working, it may take 24-72 hours for Facebook to 'see' those changes:
developers.facebook.com/tools/lint

Alex
The topic has been locked.
Support Specialist
One final note, I also just noticed you're running JFBConnect 3.2.1. That came out in April, and since then there was 3.2.2 in May which was a minor bug-fix release and 3.4 which just came out yesterday with a whole slew of new features. None of the issues changed in either release should be causing what you're seeing, but it's definitely recommended to upgrade. For the full changelog, see:
www.sourcecoast.com/jfbconnect/docs/changelog
The topic has been locked.
Active Subscriptions:

None
Thank you. Re: which version I am using, my husband installed it just about two weeks ago. I had been bugging him for a couple months on it. I suspect he clicked the link that I had sent him and not checked for updates before installing, since our install is brand new. Grrr.

You said: There are no Open Graph tags on the pages you linked. Can you double check that Open Graph integration is actually enabled in the Social configuration area?

You are right on that one, I did not have the OG integration enabled. I enabled it, then went into one of the stories I had an issue with. I didn’t see any tags before the image itself, or anywhere in the story for that matter. Always one to ‘start fresh’, I created a new story, and liked it. Story link: westminstervine.net/index.php/new-storie...d-spicy-skillet-corn
Again, this brought an advertisement with it to Facebook.

I never did find any plug-ins related to Ad Agency, so reordering related to that was not so easy. The JFBC System plug-in was already at the 0 position.

I used the Linter tool and the ‘Warning: Required Property Is Missing’ message said: ‘og: type is required’

Also, I thought this was interesting (because the first one is an ad that I didn’t want to appear). The second image is my logo, so that’s good that it seems to have set a default if no ‘first image’ is available, but it continues to ignore that first (and second) image.

Extracted 2 values from <meta property="og:image" />: westminstervine.net//images/stories/ad_agency/62/Heidi Couture block.jpg, westminstervine.net/images/stories/igall...-with-black-type.jpg

I would be happy to provide you with my user credentials--maybe I'm missing something very obvious on the back end.
The topic has been locked.
Support Specialist
The tags will actually appear in your head section, at the top of the page on the page you linked. The specific image it's using is:

westminstervine.net/images/stories/igall...mbs/Skillet-Corn.jpg


As for the incorrect image, you have to Lint before you Like the page if you've just added Open Graph tags. Facebook will only scan a page every 24-72 hours, so if the page was previously scanned and the ad was found, if you just added OG tags, the ad will still be used for the next day or so until the new tags are discovered.

Now that the page is liked though, if you Like the page, it should come up with the new 'good' image and not the ad.

Hope that makes sense. It can get confusing, but now that the OG tags will be on the page automatically, everything should go a lot smoother going forward.

Good luck,
Alex
The topic has been locked.
Active Subscriptions:

None
I remain stumped.

New story, posted last night and now that I know where to look for those tags (in the URL box), I don't see any of my stories that have those tags, and the ads are still being posted. When I linted it, again it showed the ad and 'og: type is required'....should I still be patient that I may still be in the 24 - 72 hours window?

westminstervine.net/index.php/new-storie...true-story-this-week
The topic has been locked.