1/***************************** 2 MANAGE PASSWORD RECOVERY 3******************************/ 4 5jQuery(document).ready(function(){ 6 var pcma_psw_is_acting = false; // security var to avoid multiple calls 7 8 // show recovery form 9 jQuery(document).delegate('.pcma_psw_recovery_trigger', 'click', function() { 10 var $pcma_form = jQuery(this).parents('form'); 11 12 $pcma_form.children().hide(); 13 $pcma_form.find('.pcma_psw_recovery_wrap').fadeIn(); 14 }); 15 16 17 // hide recovery form 18 jQuery(document).delegate('.pcma_del_recovery', 'click', function() { 19 var $pcma_form = jQuery(this).parents('form'); 20 21 $pcma_form.children().fadeIn(); 22 $pcma_form.find('.pcma_psw_recovery_wrap').hide(); 23 }); 24 25 26 // handle recovery request 27 jQuery(document).delegate('.pcma_do_recovery', 'click', function() { 28 $target_div = jQuery(this).parents('form'); 29 var pcma_username = $target_div.find('.pcma_psw_username').val(); 30 31 if(!pcma_psw_is_acting && jQuery.trim(pcma_username) != '') { 32 pcma_psw_is_acting = true; 33 34 $target_div.find('.pcma_do_recovery').addClass('pg_loading_btn'); 35 $target_div.find('.pcma_del_recovery').fadeOut('fast'); 36 37 var cur_url = jQuery(location).attr('href'); 38 jQuery.ajax({ 39 type: "POST", 40 url: cur_url, 41 dataType: "json", 42 data: "pcma_psw_recovery=1&pcma_username=" + pcma_username, 43 success: function(pcma_data){ 44 pcma_psw_is_acting = false; 45 46 if(pcma_data.resp == 'success') { 47 $target_div.find('.pcma_psw_recovery_message').empty().append('<span class="pg_success_mess">' + pcma_data.mess + '</span>'); 48 jQuery('.pcma_do_recovery').fadeOut(function() { 49 jQuery(this).remove(); 50 }); 51 } 52 else { 53 $target_div.find('.pcma_psw_recovery_message').empty().append('<span class="pg_error_mess">' + pcma_data.mess + '</span>'); 54 } 55 56 $target_div.find('.pcma_do_recovery').removeClass('pg_loading_btn'); 57 $target_div.find('.pcma_del_recovery').fadeIn('fast'); 58 } 59 }); 60 } 61 }); 62 63}); 64
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.