For GetMyTweets Users

I needed a very very very simple Twitter plugin for wordpress, just to show my latest tweet. I found GetMyTweets to be just simple enough. Then I started to get some warnings, and reflexively hit the Google.

But to my surprise, doing a query on “getmytweets” on google got me this:

Picture 5

I recently had a couple of warnings with the GetMyTweets wordpress plug-in. These weren’t the same warnings, but you’ll get the gist of it:

Warning: XMLReader::open()
 [function.XMLReader-open]: php_network_getaddresses:
 getaddrinfo failed:
 Name or service not known in
 /blah/getMyTweets.php on line 38

Warning: XMLReader::open(

http://twitter.com/statuses/user_timeline/joshkim.xml?count=1)

 [function.XMLReader-open]: failed to open stream:
 No such file or directory in /blah/getMyTweets.php on line 38

Warning: XMLReader::open() [function.XMLReader-open]:
 Unable to open source data in /blah/getMyTweets.php on line 38

Warning: XMLReader::read()
 [function.XMLReader-read]: Load Data before trying to read in
 /blah/getMyTweets.php on line 39

(Note to self: Fix <pre><code> later. Sorry about that, to everyone who got this post multiple times.)

Obviously, the problem is with being unable to grab the xml provided by Twitter. Due to it’s ridiculous open architecture, I don’t blame Twitter when it chokes now and then (and not as much as it did when the whole Fail Whale was in vogue). For now, I just decided to hide it. Just append the following at the top of getMyTweets.php, just like with any other PHP warnings.

ini_set("display_errors", 0);

I’m fine with this fix, because I made the title for “Recent Tweets” link up to my twitter page anyway.

Now back to Rails.

Silly Mistake: Redirecting

I didn’t know this, but there’s a tiny movement against having “www” subdomain in links. Just visit no www to read up on some of the reasons why.

>Succinctly, use of the www subdomain is redundant and time consuming to communicate. The internet, media, and society are all better off without it.

The reason why the site was “down” for the better part was yesterday was that I installed this: no-www wordpress plugin. The silly mistake I committed was that I forgot when I set up JoshKim.org, I had asked for any request to “joshkim.org” to be sent to “www.joshkim.org”.

If you visited either one of those links, you would bounce back and forth… and back and forth… and back and forth… until the browser gave up on the request. I don’t know about you, but I got this strange looking error that wasn’t a 404 or anything I’ve seen before.

I realized this error after finding out that there wasn’t any server outage reports on the Dreamhost Status Page.

Just a heads up to those that might want to follow with the rest of the Internet in making it a “www”-less world… and so that those people won’t make the same mistake as I did.