hi
I have moodle 1.9
I would like to call a javascript function when someone submits a form in moodle. (right now I'm talking about the forum mod but on any from would be ok too).
something like "onsubmit=myFunction();"
I took a look here: http://docs.moodle.org/dev/lib/formslib.php_Form_Definition
is using "addRule()" the best way ?