0

I have tried to solve this for several hours with no luck. This is my problem:

When I click a button a fancybox popup will open and show me accounts from mysql. I have a remove button in the same popup that lets me remove a certain account. When I press that remove button the popup with the accounts closes and another popup is opened asking me if I want to remove the account. When I press yes the account is removed from mysql and the popup is closed. Everything works so far but...

When I open the popup with the accounts again the account that I deleted is still there, but not in mysql. It seems that fancybox caches my account or something like that. If I quit everything and open the account popup again the account is deleted and reflect what is in mysql.

I use the following code to open and close popups.

$.fancybox.close();

$.fancybox.open('#inline16');

Can someone please tell me what is going on?

<div id="inline16" style="display: none;">
    <h3>Are you sure you want to remove the account?></h3> 
    <form id="myform" method="post" action=""> 
    </form> <br> 
    <input type="button" onclick="close_popup()" value="Cancel" />
    <input type="button" onclick="delete_account_2()" value="Yes" /> 
</div>
4

0 回答 0