require 'erb' def render(template, binding) template = File.read("#{File.dirname(__FILE__)}/templates/#{template}.erb") result = ERB.new(template).result(binding) end