get template from the html instead of doing an ajax request