Moving HTML output for options into template file.