Moving html generation into partial.