Carter Cole LinkedInCarters Twitter PageCarter Cole on Facebook Carter Coles RSS

Friday, February 12, 2010

Tweets about posts in blogger (and any other page i guess)

twitter has become one of the best ways to promote a story... and the more tweets and retweets a post gets the more accreditation and recognition the page gets. showing the tweets that a page has already received can help convey the gravity of a story and encourage others to promote the story... [for tweets about news or republish them easily you should use this embed code] but back to what we are does a pretty good job of aggregating and collecting tweets about pages... and are responsible for the cool retweet gadgets that appear on most websites. my script uses their API to pull the 10 most recent tweets about a page in the last 6 days (they dont keep them in their database past then) so lets get into what this does...

this will drop the tweets onto whatever page its currently on:
<script>document.write("<scr"+"ipt src='"+document.location+"'><"+"/scr"+"ipt>");</script>
you will need to drop this css into the page somewhere
its what does the magic and makes the tweets look all pretty :)

if your installing on blogger you can add the script at the bottom of each post by choosing "Expand Widget Templates" and adding it somewhere around the DIVs with the class post-footer-line
<div class='tweetsonpage'/>
<script expr:src='"" + data:post.url'/>

View the original post to see the tweets on the page

ok so to see the script in action just look below here (if you dont see a recent one listed tweet about this page real quick to get a demo) if there are no tweets about the page it wont drop anything in so you can leave it on pages to display once it has received all the recognition... if you have any questions or need help installing bother me on twitter im @cartercole

0 remarks:

Post a Comment

Link to this post if you found it usefull

Tweets about posts in blogger (and any other page i guess)