Learning Ruby

2 February 2012 : code, php, rails, ruby, wordpress

Some seven years ago, I began life as a web programmer by learning PHP to build my first WordPress blog. Over the past twenty four hours I’ve embarked on my first project using a “new-to-me” programming language called Ruby on Rails. While I’ve been working my way through Michael Hartl’s Ruby on Rails Tutorial Book an upcoming presentation to a potential partner led me to just jump in and start buidling a prototype. Here’s a couple of things I’ve learned:

  • Rails is very different from PHP, yet somehow more elegant
  • Scaffolds are a great way to cheat as a programmer, but messy to clean up if you do something wrong
  • Don’t use a plural name for a model (i.e. “news”) because it will cause you a world of pain
  • Google as always is your friend but be sure to add the phrase “Rails 3″ to your searches
    • That said, there are answers to your questions out there, just be patient and try to find answers on stackoverflow. They truly are the best out there.

Anyways, I’ve been at this too long. Time to go home and get some sleep. More soon!


Wait, didn’t some guy named Steve Jobs build a company on that philosophy?

9 January 2012 : apple, design, windows

Discussing the new Nokia Lumia 900 running the Windows Phone operating system in the New York Times:

“It’s not just about software,” said Albert Shum, general manager of the design studio for Windows Phone. “It’s about the whole end-to-end experience.”

Funny how good ideas take a while to be accepted.


New Year, New Theme

2 January 2012 : code, new year, php, programming, wordpress

Today, I relaunched my blog design. As regular readers of this blog will note, I probably spend more time writing about reprogramming my blog than actually writing it. I’m hoping to change that in 2012 but allow me for a minute to discuss the story behind the latest incarnation of RasheqRahman.com.

The impetus began this past summer when Twitter announced its new CSS framework called Twitter bootstrap. As I read more about the theme and downloaded the v1.0 source code, the simple, clean design tugged at me as if begging me to use it in a project. I had looked for years for a simple theme that was mainly white for the text part but had a fixed top navigation bar that could pull together my different interests (photography, writing, web development) but in a compartmentalized way so that the output of each activity could be cleanly displayed in a format that highlighted its unique characteristics. Bootstrap provides such a lattice upon which build such websites. As always, WordPress is the brains behind this project because, like the dependable friend that it is, I can connect it to my front end HTML and CSS almost immediately and know that the key files will be in the right place and easily customizable.

I vowed for this project to use as few WordPress plugins as possible, relying more on code snippets and design patterns to customize my website so I truly understood what was “under the hood.” As I hope to share in coming posts in the code category, I did this in order to improve my PHP skills and to gain a better understanding of WordPress theming. Having now completed this site and several others this year I am excited to declare that I intend to “hand roll” my own themes from here on out, i.e. using only HTML templates and adding in the WordPress code myself. If you are at the point of having configured a few existing off the shelf WordPress sites yourself and are looking to really grow as a WordPress developer, I highly recommend the “roll your own” approach.

Overall the process took some four months, with a two month long break in the middle and several pauses in the middle while I thought about the design and how I wanted everything to fit together. I decided to launch it today to kick start the New Year knowing full well that both content and design need some continued tweaking.

Look for the aforementioned coding posts in the coming weeks and please feel free to comment below. I look forward to your thoughts and questions.


The G4 is Gone! Long Live the Macbook Pro!

6 April 2008 : featured, mac, php

Today, I sold my old Powerbook G4 to someone else, bringing to the end my first Mac laptop in the modern (post Jobs’ return to Apple) era. This Mac was where I learned to program PHP and run MYSQL queries, where I first blogged and built my first production level website – www.nybap.org. It lasted for four and half years, much longer than I expected!

Fortunately, last week I purchased a new MacBook Pro 15 inch 2.4GHZ beast which will carry me forward!


Adding "cash" to my Google Finance portfolio

22 April 2007 : finance, google

Google:

If you’re listening, please add the ability to track cash in the Google Finance portfolio tracking tool. I track my portfolio in this excellent tool but I can’t enter data related to my holdings in cash instruments. I should be able to enter the cash amount as “shares” with a value of $1.00.

I’m joining the chorus of others who’ve been asking for this feature.


I'm back and now in WordPress 2.0.2

26 April 2006 : bangladesh, featured, general, php

Hi. If you are a regular reader or spammer of this blog you’ve may have noticed that the blog has been down for the past couple of days. This all started with a badly botched attempt to upgrade my blog from WordPress 1.5.2 to v.2.0.2. Within minutes of copying over the files per the upgrade instructions, I was getting the dreaded “white screen of death” in php when I tried to load my home page. For the past days I’ve been working with the good folks at Textdrive, posting on their forums, but with no luck.

However this morning, I retraced my steps a little bit and with the help of the WordPress forums and Google, I was able to piece together a hack for my wp-config.php. I’m still not sure why this works but the hack turns off magic_quotes_gpc and disables the WordPress cache. I hope if any WordPress gurus are reading they will comment and shed some light on what these hacks do. Nonetheless, my site is up and running again, so please visit once more.

Now I have to get on to writing something worth reading …


WordPress now Dashboard worthy

17 August 2005 : mac, wordpress

I recently upgraded to Mac OS X Tiger and have been enjoying the functionality of Dashboard. I like to think of Dashboard as part information swiss army knife and part virtual library. I have the EggTimer widget which I set when baking my dinner because my oven has no self-timer. I also have various dictionary and wikipedia widgets to allow me to do quicklookups without firing up my browser. It was therefore a pleasant surprise to find this morning that a new WordPress widget had been released which would allow me to post directly from the dashboard. Though its still pretty limited in its functionality I like the concept especially for quick posts. Maybe this will be the much needed insipiration to get me blogging again.


Wither Wintel?

5 June 2005 : chips, mac, windows

Word from CNET that Apple will “officially” announce on Monday that it is dumping IBM’s chips for Intel’s processors in future machines.

This got me thinking. What will happen to the epithet Wintel that Mac users used to hurl at Windows users? Is Mactel around the corner? If both operating systems share the same processor family what will Mac and Windows geeks have to argue about into the wee hours of the morning?


Increasing your visibility on Google

2 June 2005 : blogs, ego, google, new york times

I admit that I have a more than passing interest in google results for my name. It was interesting therefore to open up the New York Times this morning to see an article discussing how to expunge or promote yourself on Google. It turns out its pretty near impossible to remove all references to yourself from the web. The best way to do so is to start writing your own blog and get yourself associated somehow with heavily visited websites and blogs.


Thanks Tod!

31 May 2005 : bangladesh, featured, php

Tod Maffin wrote about my OPML project for on his blog, iloveradio.org. Let’s see how long it takes to for Tod’s entry to be the top item when you google “rasheq rahman”

(As of this writing, his original post is #10 on the results page.)

Archives