Archive for January, 2009
Rails new vs build
@article = Article.new Creates a new instance of a Model. @comment = @article.comments.build Just like the new method, but by assocation proxies (not for Models). It automatically sets the foreign_key. The other thing is that when you are doing a “has_one” the build looks like this: @comment = @article.build_comments I am writing this posts because [...]
Loud music on the bus
Working in downtown San Francisco has made my stress level rise exponentially (from zero). So much so, I am going to start a list of “People that should be shot point blank”. No judge, no jury, just shot in the head, right on the spot. To inaugurate my list are ghetto people who listens to [...]
A better Cherry Danish
I have an affinity for fruity desserts. That’s why I am always inclined to pick that sugar glazed Cherry Danish at the baked goods counter. However, there is something awfully flawed in the design of a Cherry Danish. Why is the cherry all concentrated at the center? You practically have to eat through 2 inches [...]
NPR on the HTC Touch Pro
To get the NPR – KQED radio stream to work with my HTC Touch Pro, I had to down the CorePlayer. Then from the KQED website, I download the MP3 stream, which is a .pls file. Open the file in CorePlayer and wahla, streaming NPR radio on the HTC Touch Pro. It took me a [...]