Search code examples
javascripthtmlcssaddthis

using social sharing buttons from addthis.com


Hey so I have chosen to use the social sharing widgets that are provided by addthis.com basically becuase I thought they would make my life easier, and they provide alot of data analytics free of charge. I through them into my sight without problem added metatags for facebook and everything worked perfectly on the homepage. sharing works exactly how id like it to. However i then navigated a way from home page elsewhere in site and they don't appear (I embedded them into a top panel wich occurs on everyage on the site, all same php script to print and css to format). Now ive looked at the source code for both homepage and other and it appears that add this is not pushing required data inside the tags on anywhere other then the homepage. I'm woundering if anyone else has run into this problem or can suggest a solution. You can check out the problem
homepage here and the problem page here or just navigate from home page to anyother page to view problem page. any help with why this might be happening or how to fix would be awesome.

Note: I also posted similar post on addthis.com forum a few hours ago but because it sucks/ I can't even find my post I'm asking SO to help if they can!


Solution

  • There seems to be a javascript error in funcs.js on line 51. While this may be an error unrelated to AddThis, it could be preventing other javascript from being performed. Javascript errors can have a "cascading" effect.

    SyntaxError: JSON.parse: unexpected keyword - var jsonData = JSON.parse(response);
    funcs.js line 51
    

    More info on this here: Error in one Javascript function causes others to stop working