javascript - fadeIn not working after ajax content removed -


i have following function called when link clicked. function loads new page on div through ajax , main background faded.

var original_content_benef = ''; var original_content_rc = ''; function getsummary(id) {     loadpage_signup = "new_user.php";     loadpage_benef = "readercycle_benef.php";      $.ajax({         url:"new_user.php",        datatype: 'html',        success:function() {           $(this).fadeout(710);            $("#rc_main_frame").fadeout(960);            original_content_benef = $("#readercycle_benef_container").html();           original_content_rc = $("#rc_main_header_login").html();            $("#readercycle_benef_container").load(loadpage_benef);                  $("#rc_main_header_login").load(loadpage_signup);        }     });  } 

after cancel button clicked, ajax content removed. however, main content cannot retain original opacity. please help!

function closediv(id) {     $(id).remove();     $("#readercycle_benef_container").html(original_content_benef);     $("#rc_main_header_login").html(original_content_rc);      $('#rc_main_frame').fadein(); /* problem here */ } 

html

<input type="button" id="button_cancel" name="btncancel" value="cancel" onclick="closediv('#rc_main_header_newuser')" /> 


Comments

Popular posts from this blog

php - SPIP: From Tag directly to an article -

jquery - isAjaxRequest always return false -

ruby on rails - In a controller spec, how to find a specific tag in the generated view? -