Website upgrade 2011
December 19, 2011
< 17 December 2011:
This website, robertomurray.co.uk was PHP and running (slowly) on a shared hosting server.
> 17 December 2011
The website is now on a new server and the site is mainly Ruby on Rails
Switchover
OK, here there are two major changes; 1) Migrating to new server and 2) re-written using Rails, which actually forced change #1. The previous hosting company was not very good, or rather the product and service I was getting was not very good and the final problem was not able to host rails apps properly so this forced me to migrate to a new server on which I could install whatever I wanted.
The reason for actually using Rails was because changes to dynamic pages – by dynamic I mean server processing and returning data, eg database interaction or just plain old php code – took so long to re-write, create, test, etc because they were mostly custom written, varied dependencies and sometimes overly complex. This meant that development was slow and awkward – not what web development is about.
The goal was fast, easy development, idea to deploy time as short as possible; one method to achieve this was using an MVC framework and so I tried various PHP frameworks such as Symfony, codeigniter but these did not meet the criteria I wanted. And then I got hooked on Ruby on Rails.
With Rails, I found the language, the style of programming and the design fantastic; simple concise and functional.
@travels = Travels.all(:order => "id DESC")
respond_to do |format|
format.html # index.html.erb
format.json { render :json => @travels }
end
The framework fits exactly with agile development methodology, with the addition of some extra tools such as Capistrano I can so easily add/change features, test and deploy in minutes. The site currently is 50% of what I want but I can run the site as it is now and add the extra features incrementally without a problem, each push adding functionality.
I have had to solve a few problems along the way such as;
- WordPress blog integration : my rails app is at / and the blog at /blog/ – how to integrate rails and php
- ActiveAdmin CSS problem : how to fix
- Dynamic page meta tags with Rails : A post on how to do this
Hopefully this will make adding new features quicker and easier, not only to this site but for other projects too. Enjoy and check again soon!