After the past few weeks, I was busy with the work I’m getting from my internship position with a local design firm, but I still managed to dedicate enough free time to two sites I was launching. They’re not really community-powered sites, so there’s nothing hyper about it *laughs*
Tweet Archive (link)
In light of the recent instability of Twitter, especially over the one-month span of the World Cup, I have decided that backing up my tweets on a remote server will be a wise choice. Not only does the remote server helps to archive all the tweets that I have been posting since then, it also creates a searchable tweet archive. Don’t you find it frustrating that even you yourself can’t comb through your own tweets on Twitter web interface?
However, I was only able to retrieve down to the last 3,200 tweets (dating back to August 2009). The 3,200 cap was placed on Twitter API to prevent it from being overloaded with requests… which means I’ve lost around 5000+ of my older tweets, but it’s okay.
I got the idea after Jeff (@perishable) wrote about backing up his tweets during Twitter’s wobbly period. And he has got his tweets backed up already, too.
What I did wasn’t exactly quite rocket science (maybe except for the regex part):
- Upgrade my site to WP3.0, and activate the WP multisite feature. If you’re done with this step, everything will be a lot easier. Note: Please check with your host if they support wildcard DNS, i.e. *.domain.tld. If such a feature is not offered, it’s not all kaboom. Simply create a new WP installation in the subdomain’s root directory.
- Install a new child blog pointing to http://tweets.teddy-o-ted.com
- Download your Twitter archive – I recommend TweetBackup. Export the latest 3,200 tweets (or less) as an RSS feed and download it. Try to refrain from tweeting between downloading your Twitter archive and the completion of the set up – you wouldn’t want any tweets to fall through.
- Import your Twitter archive to your WP installation. If your server is slow, the import script might exceed the 30-second execution time limit and you will encounter a timeout error. Don’t panic. Go to your WP installation and check the earliest tweet that was successfully imported. Return to your RSS file, and remove all entries prior to that, which should shave a sizeable chunk of bytes off the original RSS file. Reimport the file.
- Install Alex King’s TwitterTools WP plugin. The plugin has quite a lot of function, but I configured it such that it only imports my tweets and post them. The plugin can also create a tweet from your WP post, but enabling this feature might cause a non-ending loop (although it is claimed that the plugin is designed to avoid such fireball of death, you should be smart enough to avoid it).
- Get a theme. Doug has an excellent one, go get it. Alternatively, you can modify any WP themes you want. The theme I am using for my tweet archive is a modification of Sandbox, modeled after Doug’s theme as well.
- Regex. If you’re quick, you’ll notice that all imported tweets lack outbound links for @replies and #hashtags. I wrote a short php function to do this. Insert the following lines into your theme’s
functions.phpfile:// Makes URLs, @usernames and #hastags in tweets clickable function tweet_replies_url_filter($content) { // Prevent premature texturizing remove_filter('the_content', 'wptexturize'); // Replaces username with clickable link $pattern_username = '/\@(\w+)/'; $replace_username = '@<a href="http://twitter.com/'.strtolower('\1').'">\1</a>'; $content = preg_replace($pattern_username,$replace_username,$content); // Replaces hashtag with clickable link $pattern_hashtag = '/\#([a-z][A-Z])(\w+)/'; $replace_hashtag = '#<a title="Search Twitter for \2" href="http://search.twitter.com/search?q=\2">\2</a>'; $content = preg_replace($pattern_hashtag,$replace_hashtag,$content); /* Uses internal WP command make_clickable to replace URLs with clickable link */ $content = make_clickable($content); add_filter('the_content', 'wptexturize'); return $content; } add_filter('the_content', 'tweet_replies_url_filter');
For more information, you can read it up here. Doug has done a great writeup on establishing your own Tweet Archive.
tdy.co (link)
When the .co domain was opened to the general public on the 21st of July, I wasn’t very sure what domain name do I want. The first thing that actually went through my mind was to purchase tmun.co because tmun.com was already parked (and I have no idea why). When searching for available domain names on GoDaddy I decided to try my luck and started jamming the searchform with 3 letter acronyms of my site, my nickname or my other pseudonyms.
Try.co, taken. Tsd.co, taken. Ted.co, taken. Tdy.co, still available. What?!
I jumped. Immediately I billed $26 to my credit card and snagged the domain name before anyone else does. I had no idea what I wanted to do with it until I saw Dean’s tweet about converting his new domain, djr.co, into a personal URL shortener and I thought, hell, why not?
I downloaded a fork of Shaun Inman’s Lessn, developed by Alan Hoogan, called Lessnmore. Lessn is a great simple tool and is a lot lighter than Yourls, but it doesn’t support custom slugs unless I modify the database entry. I dug around and arrived at Lessnmore. It’s an extension of Lessn, and has a little more functionality with the same API hooks as Lessn.
tdy.co/1 points to this site :)
The tdy.co main page is a little plain. However, it is a significant example because it is my first HTML5 page. I’ve never really got into using HTML5 in my current projects because of my unfamiliarity with it, so I’m more than elated that it worked out just fine on tdy.co.






















hey coussie…are u taking on web design work on a part time basis? let me know and will intro some cust to u whenever i come across any ;)
Oh, thank you so much for the offer. I’m currently interning with a local design firm, and so I won’t be able to take any more projects. But thanks for the help! I really appreciate that :)
Simply love your work Terry! You amaze me each and everyday with the brilliance you come up with! You inspire me each and everyday!
Keep it up man! Keep it up! You are so good at what you do, you put me to shame haha! Love the tweets archive such a great idea! I’ve always wanted to see my very first tweet! AMAZING!!!
Love your URL Shortener domain! I bought IUSD.me short for (ifuseekdan.com) Still working on it :)…
I hope to be able to design like you in the future and challenge myself. You truly amaze me, and I mean that with everything! I’m not trying to suck up to ya! But man it just amazes me! :)
Thank you for the generous complements, Dan!
Your first tweet will most probably be unreachable, though. For performance reasons, Twitter has limited API calls to retrieve the last 3,200 tweets that you have posted – which means that if you have already tweeted beyond that limit, you can’t retrieve those 3,201th and beyond tweets for the moment being :/
Ah, internships. I have one now and it’s killing me a little but I love it :) Twitter instability makes me sad. I lost all of my @’s so that was a bit of a bummer but I’ll live. One of my favorite things to do before a new year is to go back and read the tweets of the previous year so I might look into backing mine up. I’m so happy you included a tutorial lol. Bookmarked :)
Nice stuff! The tweet archive is really impressive, never thought of it :D
Both “projects” sound great especially the personal URL shortener idea! :)
I understand how busy internship can be. With my new job, I don’t even have time to blog at all. Perhaps I should attend some time management courses. -.-”‘
How are you able to do so many things at once? ;)