• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

FB pulling wrong logo-image

erich37

Well-known member
#1
I just made a post at FB and entered the URL of my website into this FB-comment.

Unfortunately FB is pulling a wrong logo-image for my website.


This was actually working fine when I had "FB Connect" activated for my website, but since I have FB-Connect deactivated, it seems FB is pulling the wrong image for my website.

Where is FB pulling this image from and how can I change it ?


Many thanks!
 

erich37

Well-known member
#4
I have checked again the logo at my server. It is the correct logo since October last year and has never been changed.

Checking the FB URL and the image it is showing, you can see that FB is not pulling the "logo.og.png" image, but FB is pulling an Avatar-image (including the Avatar-ID) from my website.

Strange: why would FB pull an Avatar-image if I post the URL of my website into a FB-post ?
 

erich37

Well-known member
#5
O.K. now I see what is happening, which makes me even more confused:

when I type the URL of my website into a FB-comment-box, then it shows a different image, depending of whether I write the URL-address with capital letters or small letters:

1)
www.Example.com
when I type the URL of my website with having the very first letter in capital character, then it shows the correct "logo.og.png" image.

2)
www.example.com
when I type the URL with having the very first letter in lower case character, then it shows the wrong image for my website, literally showing an image of a User-avatar.


Facebook is getting even more scary as it already is...........:eek:
Now I am considering of deleting my FB-Page and also my FB user-account.......
 

Jake Bunce

XenForo moderator
Staff member
#6
O.K. now I see what is happening, which makes me even more confused:

when I type the URL of my website into a FB-comment-box, then it shows a different image, depending of whether I write the URL-address with capital letters or small letters:

1)
www.Example.com
when I type the URL of my website with having the very first letter in capital character, then it shows the correct "logo.og.png" image.

2)
www.example.com
when I type the URL with having the very first letter in lower case character, then it shows the wrong image for my website, literally showing an image of a User-avatar.


Facebook is getting even more scary as it already is...........:eek:
Now I am considering of deleting my FB-Page and also my FB user-account.......
Maybe some kind of caching? Dunno.

The avatar of the author is used on thread pages. You can see it in the <head> area of the source code of the page.
 

Jake Bunce

XenForo moderator
Staff member
#8
View the source code of this thread:

Code:
	<meta property="og:site_name" content="XenForo Community" />
	<meta property="og:image" content="http://xenforo.com/community/data/avatars/m/0/764.jpg?1327975937" />

	<meta property="og:image" content="http://xenforo.com/community/styles/default/xenforo/logo.og.png" />
	<meta property="og:type" content="article" />
	<meta property="og:url" content="http://xenforo.com/community/threads/fb-pulling-wrong-logo-image.28310/" />
	<meta property="og:title" content="FB pulling wrong logo-image" />
	<meta property="fb:app_id" content="146201428725181" />
Your avatar is used an the og:image.
 

erich37

Well-known member
#9
View the source code of this thread:

Your avatar is used an the og:image.
you are correct.

Code:
<meta property="og:image" content="http://xenforo.com/community/data/avatars/m/0/764.jpg?1327975937" />
this is exactly the Avatar-image which FB is pulling instead of the "logo.og.png" image.


So is this a bug in XF or a bug at FB ?
 

Jake Bunce

XenForo moderator
Staff member
#10
It's not a bug. It's a feature. Thread pages send two og images, the default image and the avatar of the thread author. If you don't want the avatar to be used then you can edit this template:

Admin CP -> Appearance -> Templates -> thread_view

Remove the red code:

Code:
<xen:container var="$head.openGraph"><xen:include template="open_graph_meta">
		<xen:set var="$url">{xen:link 'canonical:threads', $thread}</xen:set>
		<xen:set var="$title">{xen:helper threadPrefix, $thread, escaped}{$thread.title}</xen:set>
		<xen:set var="$avatar">{xen:helper avatar, $thread, m, 0, 1}</xen:set>
	</xen:include></xen:container>
 

erich37

Well-known member
#11
well, the thing is that I did not enter a "Thread-URL" into the Comment-box at Facebook.
I just entered my normal main URL as a Comment at some FB-page, and then it turned-up this user-avatar-image instead of the "logo.og.png" image.

So I thing somewhere is a bug, as it should not be the case that it shows up some user-avatar-image insted of the main Forum-Logo-og....... when entering just the normal main URL of my XF-website.

Even in the past it was working properly:
when I submitted a Thread from my Forum into some FB-page, then it showed-up the main "logo.og.png"-image, and not some user-avatar.... but now something has changed??
 

Jake Bunce

XenForo moderator
Staff member
#12
What is the URL? Check the source code of the page. Look at the og information in the <head> to see what is defined for the og:image. If the image you see doesn't match the one that is defined in the source then it must be cached.
 

erich37

Well-known member
#13
What is the URL? Check the source code of the page. Look at the og information in the <head> to see what is defined for the og:image. If the image you see doesn't match the one that is defined in the source then it must be cached.
I just send you a PC.
Would be great if you could have a quick look ?

Many thanks!
 

erich37

Well-known member
#14
as per Jake's check, it appears that the "Facebook-Connect" (Login via Facebook) is required in order to make the "logo.og.png"-image to appear, instead of having some Avatar-image appear.

I think this is a design flaw either by XF or Facebook.

I should not be the case that FB shows any user-avatars when somebody enters my Website-URL into a FB-comment-box. That will literally diminish the privacy of my members.....when Facebook shows their user-avatar insted of my Forum-logo (og-image).

So it seems we have to use "FB-Connect" in order to show the "logo.og.png"-image when making a post at Facebook.

But in my case, I do not want to use "FB-Connect".
 
#15
as per Jake's check, it appears that the "Facebook-Connect" (Login via Facebook) is required in order to make the "logo.og.png"-image to appear, instead of having some Avatar-image appear.

I think this is a design flaw either by XF or Facebook.

I should not be the case that FB shows any user-avatars when somebody enters my Website-URL into a FB-comment-box. That will literally diminish the privacy of my members.....when Facebook shows their user-avatar insted of my Forum-logo (og-image).

So it seems we have to use "FB-Connect" in order to show the "logo.og.png"-image when making a post at Facebook.

But in my case, I do not want to use "FB-Connect".

Thanks for posting this @Erich37. I am having the same problem where fb is pulling random images including images in posts and user profile pics whenever a anyone 'likes' my site. I did not initially have fb connect and this was an issue for me. I have now installed fb connect hoping this will correct the issue. As I have to wait for caching by fb, images are still be pulled from the wrong place. I know this was an issue 6 months ago for you, since then, was there anything else you found that helped correct this problem?

Thanks in advance.
 

Chris D

XenForo developer
Staff member
#16
You can edit the path to the image and the filename in Style Properties.

(Easiest way to find it is search for oglogopath in Admin CP, one of the results should be a Style Property).

I would create a new image, upload it to the same path if you like but give it a different file name. This should force Facebook to grab the new image.
 
#17
Ok thanks, I think you are talking about this:

Open your Admin Panel go to Appearance > Styles > Select Style Properties next to your style name > Header and Navigation > Change Facebook Open Graph Logo to your liking.

If you are, I have done this and changed the Facebook Open Graph image to an image with my site name by uploading an image to the server (I did this more than 6 weeks ago). Still I have this random pulling of images by fb. Unless I'm missing something...
 

Chris D

XenForo developer
Staff member
#18
Yeah that's what I'm talking about.

Damn. Facebook's caching sucks.

The weird thing as well, is that you'll find if you ask other people they'll tell you they can see the right image. So it is a bit sporadic.

I think eventually it will sort itself out.
 
#19
Hmmm, just looked at the file name in the server, the file name seems unchanged but when I click on the image, the image is my site name. I'll try changing the name and see if that corrects it.
 

Bram

Well-known member
#20
I would like FB to grab the first image of an attachment (guests can view these) instead of this logo.og.png or an avatar when content gets shared on Facebook.

Basically a first post image, as happens with Wordpress for example.

Is that possible too?