codeXplode has recently started using AddThis to allow people to share project pages. We will probably develop our own solution eventually - we don't really like how buggy the Facebook button is and may need to implement a solution that wont show a 404 iFrame when the Facebook button is unavailable.
Until then, we will be using what's available to us. And we really do like AddThis. Not their fault they're stuck trying to deal with Facebook's inconsistencies.
The one thing that bugs us about AddThis, is that, by default, it tries to figure out the url to share. Which is cool, but way off most of the time. Especially once you begin passing arguments to each page using get.
For example, a page on codeXplode may look something like this.
https://www.codexplode.com/project.php?pid=1
Although, you can specify a page argument into the url to specify which page of the project you want to see - our navigation of course takes care of this. So the same page above, could be represented as shown below.
https://www.codexplode.com/project.php?pid=1&page=d
Both urls take you to the same page. The page=d just tells php to show the details page for the project. But if you don't specify a page, then it shows that page by default - to ensure something is shown.
This results in broken visitor analysis being performed by AddThis. Each of the above urls used to show completely different statistics.
Here's the fix. This is documented by AddThis, just can't remember where.
Simply add a addthis:url="http://example.com" to each of the anchor tags in the snippet that AddThis gives you to put into your page.
Hope this helps someone out there.
No comments:
Post a Comment