I figured it out! It took a couple of days, but here it is. I am not
expert but here is what did it for me. For some reason, it doesn't
work when you put the javascript on the page itself. It won't
recognize the functions. But if you put it in an external file, it can
see it. I don't know why, but
not sure of your problem... but try to put the java function BEFORE
the ajax calling and give it a try. Javascripts always mess with me in
this kind of way... maybe it helps you.
function testCall() { alert('[EMAIL PROTECTED]');}
form('addComment', 'post', array(
'model' => 'Comment',
The "complete" option works fine if I put the javascript directly into
the array. However if I try to put it in a function in the array it
doesn't work. Take the following example:
form('addComment', 'post', array(
'model' => 'Comment',
'url' => array('controller' => 'comments', '