The case against MBAs

Have friends who wants to go to business school? Please save their souls (and their livers): An infographic detailing the cost of an MBA. The Economist: Think twice The return on investment on an MBA has gone the way of Greek public debt. Business Insider: 40 Years Of Data Show The MBA Effectively Does Nothing …

iMessage and T-Mobile Monthly4G prepaid

I have a factory unlocked iPhone 4. It was running iOS 5.0.1 and has a T-Mobile SIM in it. Voice, text, data and MMS all work as expected. This morning, I was unable to activate iMessage. Several times, it got stuck “waiting for activation.” Eventually, it displayed an “Activation Failed” message. I tried removing my …

HOWTO count words in JavaScript

Here is a handy JavaScript function for counting words: String.prototype.countWords = function(value) { // remove html tags var cleanedText = this.replace(/< .[^]*?>/g, ' ') // remove numbers and punctuation .replace(/[–—.(),;:!?%#$‘’“”'"_+=\/\-]*/g, '') // remove/coalesce space chars .replace(/(&nbsp;|&#160;|[ ])+/gi, ' '); // don't split "" into words, as you'll get 1 ([""]) if (cleanedText === "") { …

HOWTO set up IMAP email for Yahoo

A few weeks ago, I was helping my cousins set up their new iMac. Once everything was up and running, she inquired about adding their Yahoo account to Mail. The conventional wisdom says you can’t do this. Yahoo charges for POP access. IMAP? Unavailable. But then she hands me her new iPod touch…with her Yahoo …

HOWTO setup multistage deployment with Capistrano

These instructions are outdated. They were written for Capistrano 2.x. As of March 2016, Capistrano 3.x is current. When I wrote about deploying PHP sites with Capistrano, step 6 was a bit of a throwaway — hey, here's a quick hack for handling multistage deployment. I'd been using variants of that technique for quite some …

Fixing iChat Google Talk login failures

I was helping a friend set up her new iBook MacBook yesterday, and we were unable to get iChat to log in to her Google Talk account. We kept seeing this error: iChat can’t log in to talk.google.com because your login ID or password is incorrect. And this XMPP error was logged to Console: iChatAgent[33567] …

WordPress batch upgrade

If you run a web server and have multiple installations of WordPress, upgrading them all is a pain. Wouldn’t it be nice if you could update a dozen WP installs at once? Wouldn’t it be even better if you could update the Akismet plugin at the same time? (WordPress releases independently of Akimset, and their …

How to solve the “undefined method `deep_symbolize_keys’ for nil:NilClass” error in Rails

I was trying to migrate a table in my Rails app and got this error: undefined method `deep_symbolize_keys’ for nil:NilClass It’s a strange error, and there weren’t very many hits on Google. A lighthouse ticket provided a clue. The problem wasn’t one of my plugins or gems — it was i18n itself. Upgrading from 0.4.1 …