Implemented SMTP emailing

Adds the ability to use Email exports in XML definitions.