Preamble for my question:
I have a web application (or a site, this is an internal LAN site) that makes extensive use of jQuery and AJAX to dynamically load a section of the user interface content in a browser. The user brings the application to the navigation menu. Clicking an item in the navigation menu calls an AJAX call to php, and then php returns the content that is used to populate the center of the content.
One of the pages served by php has the form of a table configured as a spreadsheet in which the user enters values. This table is always stored in synchronization with the data in the database. So, when the table is created, it is populated with the appropriate database data. Then, when the user makes changes to the "cell", this change is immediately written back to the database, so the table and database are always in sync. This approach required to convince users that the data they entered was saved (long story ...), and to make it easier for them to press a save button of any type.
So, this is always a great idea in synchronization, except that the user can enter a value in the cell, not remove focus from the cell, and then take any number of actions that could lose the last value: for example, go to another section of the site through the navigation menu , exit the application, close the browser, etc.
End of the preamble to the question:
, , , "" , onunload . : - ( , ) AJAX URL- , , . onunload , .
: , "" , ?
, , , , , , , , , .
, !