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!


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.


Ending the WordPress Themes obessions … for now

1 June 2007 : blogs, themes, wordpress

Over the past few weeks, I’ve been trying new themes on my blog almost daily. I’ve recently become enamored with 3-column, widget ready themes that allow you to move items like archives, recent comments, etc. around on the sidebars without programming.

However, with so many different themes out there and new ones being added daily, I find it hard to keep up. More importantly, having so many choices makes me fickle and apt to change themes frequently. As a result, I spend more time trying themes rather than writing.

Therefore I’ve declared a six month moratorium on changing my blog themes. I’ve adopted a suitably named theme called plaintxt by Scott Wallick of Barthelme fame. It’s boringly plain but easy on the eyes and I feel good for content which I hope to create more of in the next couple of months. I’m toying around with the idea of adding theme links to my del.ici.ous account and then trying them out after my six month hiatus. I’m a big fan of really simple themes with lots of white space good for text. One design I recently found quite impressive was http://www.youtilize.com/. It’s the kind of clean design I really like and I hope that one day the author open sources the design.


Squible don't like default categories

27 November 2005 : themes, wordpress

Just a quick note. The “teaser post” at the top of the main page in the Squible wordpress theme doesn’t seem to like any post that’s tagged with the wordpress default category. The default value for this category is “General” so if you remove the “General” category from your post it’ll display properly in the teaser section. I found this by trial and error so I thought I’d save my readers some trouble if they choose this otherwise excellent theme.


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.


A new design again …

26 May 2005 : themes, wordpress

If you are regular at my blog, you know I have this almost bi-monthly fascination with changing the layout of my blog. This is largely due to my rapidly expanding knowledge of WordPress, css, and elements of good web design. I readily admit to suffering from “Gee that’s cool, why don’t I make my site look like that” syndrome. This incarnation was borne of the realization that my previous theme, while aesthetically beautiful, was hard to read comfortably. As I started hunting for a replacement WordPress theme my focus turned towards finding something that was simple. I googled for lists of wordpress themes and came across Emily Robbins’ exhaustive list of WordPress Themes.

I literally began clicking through this list until I came across a design called Conestoga Street by Theron Parlin. The theme caught my eye because it is very simple using a white background with black texts and selective coloring to highlight post titles, links and meta data. I also liked the fact that a single vertical bar separated the posts from the menu information on the right. I knew that I wanted to use a few WordPress plugins to display information on the right but I didn’t want it to look to cluttered by having the side bar boxed in.

Tweaking the design took a few hours of fiddling with the Theme editor but I think I have something usable and easily skinnable. Once I have some time I might investigate writing a script which would allow me to change the css stylesheet depending on the time of day so a visitor would see a different color scheme as the day wears on.

That is unless I get bored with this design and find something else.


All about folksonomies

7 May 2005 : blogs, folksonomies, wordpress

I just installed Cat2tag a wordpress plugin to add folksonomies to WordPress. Though I’m not yet a power blogger (i.e. I don’t blog multiple times a day or for that matter multiple times a week), as a power del.icio.us and scuttle user, I can immediately appreciate the value of being able to create tags on the fly.

My only gripe is that I would love it if Edmundo could make tags comma separated instead of space separated. I like the multi-word categories names without underscores.