converting slideshow to use rails template instead of handlebars