Ravings of a Maven
Taken with instagram

Taken with instagram

Taken with Instagram at Nashville, Tennessee

Taken with Instagram at Nashville, Tennessee

Taken with instagram

Taken with instagram

So I was thrown a hurdle by one of my clients the other day that forced me to think of a simple solution to the problem. He had text that he wanted to store into the database and, later on, pull this data and replace the placeholders. While this would have been made simple through a view, he wanted the ability to edit this text later on. 

So I had placeholders in the form of <name>, <city>, etc and had to have a way to replace the placeholders with user submitted information. The solution I came to was:


@page.each {|key, item| @content.gsub!("<#{key}>", item.to_s)}

This simple one liner worked beautifully and allowed the administrator/client to modify the copy text when needed from a form. This may not be a full blown template system but it works enough, on a small scale, to deal with a simple client problem.

As you might have noticed, the page is quite sparse in terms of posts. This is due to the fact that I recently decided not to have tweets post directly to my blog/portfolio anymore. So, as most lumberjacks do whilst frolicking in the overgrown forest, I proceeded to cut them down one by one. Needless to say, I had A LOT of tweets. What now? Well, I hope to be posting more informative posts in the future. Tutorials, Status of my skills, etc etc and so forth.

I also hope to bring more writing to this blog as I need to boost my writing portfolio. This will mean short stories, poems, small articles, etc. You will probably also see those days where I am sitting in the corner of the blog, a jar of my own feces, raving about the musings of a Ruby on Rails maven. Want to hire me? Well… I added a hire me tab on the site so have at it! Click that bad boy!