This quite easy to do thanks to the elegant design of moodle (OK, I'm brown nosing).
For moodle 1.4.4, look in
mod/forum/lib.php
for the functions
function forum_make_mail_text
function forum_make_mail_html
function forum_make_mail_post
Forum
Posting and receiving email
This discussion has been locked so you can no longer reply to it.