Thursday, December 31, 2009

Uploadify "406 Not Acceptable" error with Rails

To some poor souls out there, if you encounter "406 Not Acceptable" error when uploading file with Uploadify on IE, Firefox, or Chrome on Windows, you may want to remove or replace the respond_to block, if you can.

From what I can figure out, those Windows browsers send text/* as the HTTP_ACCEPT header, while on Linux, it sends */*. I suspect this is caused by different behavior of Flash on different OS and the header from Windows is considered invalid by Rails.

Tuesday, December 29, 2009

Reading obscure texts

I've just read Zed Shaw's The Master, The Expert, The Programmer. Talk about the obscure Go Rin No Sho (The Book of Five Ring) by Miyamoto Musashi, I'm thinking that maybe it's good to read those obscure texts like The Art of War or Zen koans. They're supposedly full of wisdom, but we don't understand them. We simply don't because we've lost the context (in the case of Go Rin No Sho and The Art of War) or it's intentionally created to be non rational like the Zen koans.

It may be able to train your creativity, flexing those neuron connections, making you think outside of your daily thoughts and peering deep into yourself. And since it's obscure, the answer you get is most likely something inside you which you probably have never known.