开发者

URL change, retaining facebook likes

开发者 https://www.devze.com 2023-03-20 18:13 出处:网络
We have launched the Facebook like button on our site, and it\'s being used which is great. However, our page URLs do sometimes change (they are profiles of people who provide a service, and the filen

We have launched the Facebook like button on our site, and it's being used which is great. However, our page URLs do sometimes change (they are profiles of people who provide a service, and the filename changes for SEO reasons when their services change, we currently 301 redirect from any old address to the new one).

I imagine though that when we change their URL, we will lose the facebook like count from that page, as Facebook will probably see it as a different page.

Does anyone know if there is anyway around this? I can't see that facebook can r开发者_运维知识库everse lookup the old address to associate it to the new one, since it simply won't know about this URL change, unless there is some way to inform Facebook?


I think this is achievable. In the Facebook 'Like' HTML button code there is a parameter for the href (i.e URL)

<div class="fb-like" data-layout="button_count" href="http://www.website.co.uk/projects/cool-project/" data-width="40"></div>

So you can be on one page, while liking a different URL. I use this to aggregate the likes of a page across multiple domains i.e website.com and website.co.uk and website.es

So if you have a back-end CMS then you could develop it so that it has a field for the Facebook Like URL, which is different to the actual page URL. As long as you always leave the Facebook Like URL as the original URL that you began accumulating likes, then it shouldn't be a problem.


This is currently not possible. You can try to contact them, but I doubt they'll move your likes.


Just to let you know that this doesn't seem to work anymore.

I did change all my URLs structure, made 301 redirects, added tags like this pointing to the old URLs:

  • canonical
  • og:url

And pointed Facebook like widget to the old URL like this:

<div class="fb-like" data-href="http://jchatard.com/blog/2013/09/26/usa/" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>

And all my likes have gone.

I also tried to re-like one the post, to give it a try, like explained here:

  • http://techwelkin.com/domain-change-get-facebook-like-count-back

No luck!

For whatever reason, this URL still has its likes count, I really don't know why:

  • http://jchatard.com/fin/

If someone has a clue, or updated behavior, that would be cool!

0

精彩评论

暂无评论...
验证码 换一张
取 消