BlogHarbor Home Page
FAQFAQ  SearchSearch  MemberlistMemberlist  UsergroupsUsergroups  UsergroupsRSS   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
Integrate ShareThis social bookmarking
 
Post new topic   Reply to topic    BlogHarbor Community Forum Index -> Tips and Tricks
View previous topic :: View next topic  
Author Message
bkuerbis



Joined: 30 Oct 2008
Posts: 2

PostPosted: Tue Apr 07, 2009 8:56 am    Post subject: Integrate ShareThis social bookmarking Reply with quote

I'm implementing ShareThis, a social bookmarking tool, within my blog (http://blog.internetgovernance.org/). It was easy enough to edit the Article template and get it working correctly, but I'm having some issues getting the Category template working correctly.

For the Main page, I have this in the head section:

Code:
<script type="text/javascript" src="http://w.sharethis.com/button/sharethis.js#publisher=ff7d9cb3-f25f-4888-bef3-e786c47f2fc9&amp;type=website&amp;post_services=facebook%2Cslashdot%2Cdigg%2Cdelicious%2Ctwitter%2Corkut%2Cstumbleupon%2Creddit%2Ctechnorati%2Cmixx%2Cblogger%2Ctypepad%2Cwordpress%2Cgoogle_bmarks%2Cwindows_live%2Cmyspace%2Cfark%2Cbus_exchange%2Cpropeller%2Cnewsvine%2Clinkedin"></script>


and this in the Category template:

Code:
<script>
   SHARETHIS.addEntry({
      title:'{{title}}',
      summary:'{{excerpt}}',
      url:'{{permalink_url}}',
                icon: 'http://path.to/icon'
   }, {button:true} );
</script>


It's generating the correct html, but I only see the "ShareThis" button and link under one Article when viewing in browser.

Any ideas what's wrong?

Thx
Back to top
View user's profile Send private message
john
Site Admin


Joined: 16 Mar 2004
Posts: 3434

PostPosted: Sat Apr 11, 2009 1:15 pm    Post subject: Re: Integrate ShareThis social bookmarking Reply with quote

Looks on your blog like you figured this out?
Back to top
View user's profile Send private message Send e-mail Visit poster's website
bkuerbis



Joined: 30 Oct 2008
Posts: 2

PostPosted: Sat Apr 11, 2009 2:29 pm    Post subject: Reply with quote

Yep. The links in the article summary were tripping up the script. Just converted (excerpt) to a string and it now works fine. Here's the code:

Code:
<script>
   SHARETHIS.addEntry({
      title:'{{title}}',
      summary: '{{String(excerpt)}}',
                url:'{{permalink_url}}',
                icon: 'http://path.to/icon'
   }, {button:true} );
</script>
Back to top
View user's profile Send private message
Search all BlogHarbor support resources.
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    BlogHarbor Community Forum Index -> Tips and Tricks All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum