






















August 6th, 2018
AddToAny Share Count Recovery is a free & mighty feature for publishers using share counters.
You can recover lost share counts when moving to HTTPS, a new domain name, or a new URL structure. A previous URL’s share counts are simply added to the current URL’s share counts, so you won’t lose your new counts.

As websites transition from plain HTTP to encrypted HTTPS, publishers are finding that share counts — especially Facebook Likes — reset to zero. This is because Facebook considers http://example.com/ and https://example.com/ to be completely different URLs.
Facebook offers technical guidance on how developers can redirect URLs and exempt their crawler from redirects to retain share counts. This is doable for some developers and WebOps teams, but the Facebook crawler exemption can be difficult to setup, awkward to maintain, and it still doesn’t cover Pinterest and Reddit.
With AddToAny share count recovery, it’s just one line to combine counts for the HTTP and HTTPS versions of shared URLs.
HTTP recovery applies to Facebook, Pinterest, and Reddit. Some services — such as Tumblr — are ‘protocol neutral’ with shared URLs, meaning they consider http://example.com/ to be the same as https://example.com/. So if you’re only recovering HTTP counts, AddToAny skips the extra lookup for unaffected services such as Tumblr.
Whether you’ve switched to a new domain name or a new subdomain, AddToAny has your domain recovery needs covered too.
Just place your old domain name in a line of code as demonstrated in the share count recovery docs.
For more complex changes, AddToAny lets you script out your own recovery logic within a custom JavaScript function. A helpful data object is passed to your custom recovery function, making it convenient to reconstruct an old URL structure based on parts of the shared URL, such as the domain, protocol, and pathname parts. You can also get values from any HTML data-* attributes you may have provided, such as a post ID, day, month, or year.
See the WordPress, Drupal, and HTML guides for how to use share count recovery to get your share counts back.
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。