The messages like $(....)ajaxForm is not a function means that smth isn't good with the JQuery forms library connection. In the PHP code it can be added like this way:
$oTemplate->addJs(array('jquery.form.min.js'));