I've been on a bit of an upgrade kick recently. Part of it is my small fascination with Empire Avenue, and part of it has been the new found time since completing school. I'm sure there is also a part that what is "just because". All-in-all, here's what I've done
RSS Tweaking
The first big change I did was changing up my RSS. Since I'm using my RSS on @EmpireAvenue I noticed the duplication of twitter feeds. And since most of my social networks include a twitter import, I figured, why repeat? So I am filtering our all my tweets from the RSS. And for those that are using RSS to follow me, sorry, but you're just going to have to watch my on @ethernick
Eavify
A great little jquery plugin from Olivier which converts ( e )OL into (e)OL.
Formspring.me
I've been wondering about the uses of formspring.me. I've got an account, but don't promote or use it much. And since Facebook Questions is taking forever, I figured why not put a little weight behind it. And while I'm at it, make a Storytlr plugin for it! So It did.
Github
And since I was promoting my plugin to Github, it occurred to me that I need to add that feed to my site as well. So ,thanks to John's diligent Stortlr plugin wrangling, I found one already made.
With Twitter making the big change to dump basic authentication, it looks like if you pass a username and password through curl, then you'll be getting a 401.
So What do you do?
Well, I changed 2 things to ensure I fall inline with the api:
- Change the fetch domain in TwitterModel.php (Line:96)
was:$url = "http://twitter.com/status...
change to:$url = "http://api.twitter.com/1/status...
- Comment out the curl username and password (Line:92)
I've just added @Anywhere to this site. It's was relatively easy. Here's what I did.
1. Signed up
First things first, you need to goto @Anywhere and sign up. Add your application name and webiste details. It's pretty straight forward. From there they give you a code to copy and paste
2. Updated default.phtml
I opened protected/application/public/views/layouts/default.phtml and pasted the code I got into the <head>
<script src="http://platform.twitter.com/anywhere.js?
id=<YOUR ID GOES HERE>&v=1">
</script>
<script type="text/javascript">
twttr.anywhere(function(twitter) {
twitter.hovercards();
});
</script>
3. Updated Timeline/view.phtml
As an added bonus, I figured that if I were to get a comment on a tweet through my site, then it should go through twitter. Makes sense, yes? So I added this little snippet into protected/application/public/views/scripts/timeline/view.phtml.
if ($this->item->getType()=="status") : ?>
<div id="tbox"></div>
<script type="text/javascript">
twttr.anywhere(function (T) {
T("#tbox").tweetBox({
label: "Your thoughts?",
height: 100,
width: 400,
defaultContent: "@ethernick "
});
});
</script>
I inserted it just below
echo "<div class='date' id='".date("YMj", $timestamp)."'>$date
</div>";
echo $this->partial('timeline/item.phtml', array('item' => $item,
'admin' => $this->admin, 'model' => $this->model,
'disqus' => $this->disqus, 'googlefc' =>
$this->googlefc));
And Blam-o!
Roll over these to see the hovercards: @ethernick @breakingthedial
Or if you want, checkout one of my tweets to see the tweetbox in action
You may have noticed the zootool, dailybooth and vi.sualize.us plugins on my site.
With the help of SimplePie, I made them myself.
Thanks to the request of John, I've put them up on github for all to use and download. I'm no code monster, but I can hack away.
Feel free to use and improve them.
When I looked at Storytlr, the key was that I could make my own plugins. Which, I've done with my vi.sualize.us and dailybooth add on's (I'll share them later). But, I had to make some changes.
First, storytlr uses the zend framework, something that's still a little foreign to me. So I needed to add a library that I could work with.
Enter SimplePie
It's relatively easy to impliment. But there were a couple hiccups along the way.
- Download SimplePie 1.1.3
note: don't install 1.2 because for some reason, it will end up repeating the same posts over and over and over. - Rename simplepie.inc to SimplePie.php
note: some servers are case sensitive so make sure of naming - Drop SimplePie.php into ./protected/library
- Edit ./protected/application/Bootstrap.php
113: error_reporting(E_ALL & ~E_STRICT);
note: if you don't then your log file will be bombarded with php strict errors that are just clutter - Edit ./protected/config/config.ini
31: debug = 0
note: your could keep debug on (debug = 1) but then others will see all the little errors on your site when something goes wrong.
Now SimplePie is a free for all to use
private function loadFeed($url) {
$feed = new SimplePie();
$feed->set_feed_url($url);
$feed->enable_cache(false);
$feed->init();
$feed->handle_content_type();
return $feed;
}



formspring.me
