parsing mail headings; added template