confirmation dialog that continues submit, or cancels and resets button

confirmation dialog that continues submit, or cancels and resets button

i'm trying to make jquery UI's button and dialog plugins work with my form. i want the reset button

  1. <button id="opener" value="reset" type="submit">Reset</button>

to pull up a confirmation dialog, which it does. cancel should dismiss dialog and set the button back to its original state. it dismisses fine but the button maintains its hover state, even though i have tried adding the .refresh method just about everywhere i can think of.

  1. jQuery(document).ready(function($) {

    $

    (".dialog").dialog({
                autoOpen
    : false,
                resizable
    : false,
                modal
    : true,
                title
    : 'Warning!',
                close
    : function () {
                    $
    ('#opener').button('refresh');
                   
    },
                buttons
    : {
                   
    'Continue': function() {
                        $
    (this).dialog('close');    
                   
    },
                   
    Cancel: function() {
                        $
    (this).dialog('close');
                        $
    ('#opener').button('refresh')
                   
    }
               
    }
           
    });


    $


    ('#opener').click(function() {
                $
    ('.dialog').dialog('open');
                $
    (this).button('refresh')
               
    return false;
           
    });
    });

then on a Continue response the button should continue with its original purpose.. which doesn't happen. i get a return: false type of behavior w/o return: false anywhere.  can anyone point me in the right direction?