I'm building a form - I've got one field where I'm allowing the user to
select a radio button (selecting a division) and then doing an Ajax call
to populate a related text field with a name.  I've got a little
animated 'ajaxy' graphic that pops up to show activity:


        // get division director - via radio button (divisionID) - ajax
call
        $("input:radio[name='divisionid']").click(function() {
                var foo = $(this).fieldValue();
                $.ajax({
                        type: "GET",
                        url: "index.cfm?action=telework.getchief",
                        dataType: "html",
                        cache: false,
                        data: "divisionid=" + foo,
                        success: function(msg) {
                                $('#approval_2_Yes_2').val(foo);
                                $('#approval_2_Yes_2display').val(msg);
                                // alert('Division ID = ' + foo);
                                }
                });
        });
        // show loading graphic
        $('#loading').ajaxStart(function() {
                $(this).show();
        }).ajaxStop(function() {
                $(this).hide();
        });

But now I'm adding a few fields which are using Jorn's autocomplete. One
of these fields is right next to the radio buttons above - and when I
enter data - the Ajax call kicks off and my graphic for the other field
shows up :\

If it possible to define WHICH Ajax call you want the ajaxStart applied
too?  Or is there a better way to tackle this??

Thanks,
Jim

Reply via email to