Fixes for #41 and #54

Proposed fixes for #41and #54
Not the neatest fix for #41 as it includes inline javascript to allow the haml processor to be run to add the Redmine relative_url_root parameter.