HTML safe and escaped text in a rails view

In my skilling up in Rails application I was wanting to add in the feature to allow a user’s comment/post, if it contained a URL, to make that URL clickable. A fairly simple change but one with a bit of a trick on Rails as it turns out. Continue reading “HTML safe and escaped text in a rails view”

VIM and my configuration

As with most vim users above beginner I used to have my customised vimrc file.  Since being off vim for a while and changing machines a couple of times, I now can’t find where I had stored my previously developed vimrc file so I’m building a new one.  Also in common with many other developers I’ve made a github repo to store it so next time I need to find it I’ll know exactly where it is.  So if you are interested to see what’s in it and how it develops,  you can find it there.

Going live with my test application

I’ve been building a sample web site/application in Ruby on Rails.  I’ve been following the, what I think is, rather excellent tutorial by Micheal Hartl.  I’ve finished the base tutorial and am now looking to expand the site with some improvements and fixes I think it needs and then use it as a base to fork into other projects.

I’ve deployed a test version on the Heroku cloud platform here: https://polar-bayou-3372.herokuapp.com/

I’ve also got a project repository with project tracking on bit-bucket here: https://bitbucket.org/damienjbyrne/sample_app

Anyone who wants to have a look, give it a try, and send back some feedback is welcome to.

Psychos and code

I was researching a programming issue today and came across this fantastic quote from a usenet post in 1991, still good advice today:

“Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.  Code for readability.”
– John F Woods

Continue reading “Psychos and code”

If people were programming languages … again

Well that’s weird. I took a quiz back in 2009 and was personality matched to the programming language COBOL (old and stodgy but reliable).  I came across the link and had another go and this time I got:

You are PHP. You enjoy the World Wide Web. You are constantly changing the way you do things, and this tends to confuse people who work with you.
Which Programming Language are You?

And what’s wierd is that I’m currently working in PHP. Ain’t that funny?

Source: If people were programming languages