If you want to set it so all PM's proces both html and ubbcode, change this line in /scripts/sendmessage.inc.php
$Message = $html -> do_markup($Message,"post","markup");
with
$Message = $html -> do_markup($Message,"post","both");
This not handle preview correctly yet.
All in all, there is no need to fiddle around in javascript whatsoever, it's mostly stuff that calls php scripts for the actual work.