Topic-icon K2 Likes OK but all Comments are missing after upgrade

Active Subscriptions:

None
Hi, sorry to bother you again :)

The Joomla upgrade from 2.5 to 3.4 went well, except that all the K2 Comments are missing.

This article, for instance, had 6 comments. All the Likes are there, but no comments...

www.thailandstidende.com/component/k2/it...partybaren-jubilerer

Best regards
The topic has been locked.
Support Specialist
Can you check if you have the Open Graph - K2 plugin enabled? On the page, I see that the URL for the Like and Comment feature is the same. However, the og:url tag, which is separate, is for the following URL:

www.thailandstidende.com/component/k2/it...partybaren-jubilerer

I'm guessing that the comment box is associating comments with that incorrect URL. Enabling the Open Graph - K2 plugin should hopefully fix that.

Let me know if that helps or not and we'll gladly investigate further if necessary.

Thanks,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56280 by dageke
Thanks, I enabled the Open Graph - K2 plugin but nothing changed... Cleard the cache in my browser too, but nothing... So perhaps there is something else.
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56281 by dageke
I notice a few more plugins from SourceCoast that are disabled. Should all be enabled?
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56282 by dageke
I did move the site from a subdomain to public_html after I installed the new version. I noticed that in the component the subdomain was still listed, so I changed that. But still no effect.

... disabled plugins:
Open Graph - Content
Open Graph - Custom Object
Social Profiles - Custom DB
Social Profiles - Joomla
Social Profiles - K2
The topic has been locked.
Support Specialist
8 years 3 months ago #56289 by mel
Those plugins should be fine to be disabled. The Social Profiles plugins are for importing data into your third party profiles when logging in via social networks. The other Open Graph ones don't apply in this situation.

The URL you provided was www.thailandstidende.com/component/k2/it...partybaren-jubilerer but the comments widget on that page is configured for www.thailandstidende.com/item/2847-partybaren-jubilerer - if I plug in both into Facebook's comments configurator, I see different comments counts. When I put the new URL into the browser, it's redirected to the old page. The JFBConnect content plugin is just querying K2 to get the correct URL for the comments plugin, but the problem lies in that there are multiple ways to get to the same article. K2 is now returning a different URL for the page than it used to. My guess is that when you switched the subdomain, this happened.

-Melissa
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56290 by dageke
Hi, thanks for looking into this. I got rid of the url rewrite.

You will notice that the item now stays on url www.thailandstidende.com/item/2847-partybaren-jubilerer

But still no comments...

I had to change K2 advanced SEF settings and edit the file .htaccess to end up with the correct url... but to no avail it seems. Or is this a cache thing now?

Best
The topic has been locked.
Support Specialist
It looks like we went in the wrong direction. Now, I see no comments or Likes on that page. However, since some of the redirections were cleared up, it's easy to tell that the old site used the /component/k2/.. URLs for your content.

You can see now by putting both URLs into the Facebook Comment tool:
developers.facebook.com/docs/plugins/comments#configurator

Since the redirect is gone, both URLs work as expected and show the old comments on the /component/ URL and no comments on the /item/ URL.

There's no way to transfer comments from one URL to another. The only recommendations I can give are:
* Setup your site to use the /component/k2/... URLs
* Manually insert some tags onto the page you want to salvage the old Likes & Comments from to instruct Facebook to link to those pages. Then, Facebook will link to those 'old' pages and you'll need to make sure there is a redirect to the correct page on the new site. This is a manual task you'd need to do on each URL you want to fix.

Unfortunately, this is a common issue when new SEF extensions are configured on your site or even during upgrades of Joomla itself. URL structures change and there's no way for JFBConnect or Facebook to know what the proper URL to use is.

I hope that helps explain,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56292 by dageke
OK, so I have now reversed the changes I made and I am back to the old URLs

The strange thing is, that other k2 items still have the Likes (but not the Comments), like this item,

www.thailandstidende.com/component/k2/it...er-satser-pa-jomtien

which has 196 Likes and 4 (missing) comments.

So, why have the Likes disappeared from one item and not from the other?

You say I have to manually alter all our items (we have about 1800 K2 articles in total). This is not a good situation. Moreover, I did not understand your method regarding tags ("Manually insert some tags onto the page...etc"), could you please explain?
The topic has been locked.
Support Specialist
Unfortunately, Facebook does things differently for each of it's plugin. Here's all the different URLs used on that page:
Actual URL:

www.thailandstidende.com/component/k2/it...er-satser-pa-jomtien

Open Graph URL:

www.thailandstidende.com/component/k2/it...er-satser-pa-jomtien

Like Button URL:

www.thailandstidende.com/item/2838-quizmaster-satser-pa-jomtien

Comment Box URL:

www.thailandstidende.com/item/2838-quizmaster-satser-pa-jomtien


The Comment box will always use the URL provided to it. The Like button will first check if the og:url tag is set and, if so, use it. If not, set, it will fallback to the URL set for the button itself.

Because of the differences above, the Comments are using the newer, different URL style. The Like button is using the og:url that you've reverted to.

In general, JFBConnect tries to get the URLs the same way for all the social buttons. Since we understand how K2 works, we can request the better, canonical URL which uses item/. The og:url tag is always set the current URL though. We've tried in the past to set this to different, possibly better, URLs, but it generally causes Facebook to go into a loop when redirecting all through your site.

The ultimate goal of JFBConnect though is to create one specific URL for each piece of content of your site, which is what our social buttons are doing. Whether you're on the /component/k2 or /item/ version of the page, our social buttons will use the same URL so that all social features are attributed to that page. When you upgrade Joomla or K2, the underlying routing to those URLs can change and there's no way for JFBConnect to work around that.

I hope that helps explain things a bit more,
Alex
The topic has been locked.