Quote:yes i am using a ajax in a pop up window.
Make sure the buttons are disabled by default.
In the success part of your AJAX routine, enable the buttons. If you give both buttons the same css class, you can enable them in jQuery by removing the disabled property:
Code:
$('.image-action').prop('disabled', false); //this will enable all elements with the "image-action" class.