Custom functions

Custom functions


Im fairly new with using jQuery. I setted up a demo modal window that
parses a ajax call. At the return of the ajax call a javascript
function can be called. Here is a short demo:
$(function() {
tips = $("#validateTips");
        function updateTips(t) {
            tips.text(t).effect("highlight",{},1500);
        }
function popper1() { alert('y'); }
$("#dialog_login").dialog({
            bgiframe: true,
            autoOpen: false,
            height: 100,
            modal: true,
            buttons: {
                'Login': function() {
                    ajaxObj.call('action=login' + ajaxObj.getForm('login'),
ajx_fill);
                    $(this).dialog('close');
                },
                'Annuleren': function() {
                    ajaxObj.call('action=login' + ajaxObj.getForm('login'),
ajx_fill);
                    // $(this).dialog('close');
                }
            },
            close: function() {
                allFields.val('').removeClass('ui-state-error');
            },
plopper2: function() {
alert('x');
}
            });
        $('#login_button').click(function() {
            $('#dialog_login').dialog('open');
        })
    });
in the return i can use: $('#dialog_login').dialog('close') but i want
to call a custom function like the plopper1 or plopper2 function.
I would also like to be able to use a custom function in a onChange
statement in my form.
Anybody?