Have a look here: http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/324675/help-needed-please-update-database-on-browser-close. I think this is what you are after.
More Related Contents:
- Best way to initialize (empty) array in PHP
- How do I get the function name inside a function in PHP?
- Sending POST parameters with Postman doesn’t work, but sending GET parameters does
- Is header(‘Content-Type:text/plain’); necessary at all?
- If you create a variable inside a if statement is it available outside the if statement?
- How to get an option previously set with curl_setopt()?
- How to stop GD2 from washing away the colors upon resizing images?
- How do I check in PHP that I’m in a static context (or not)?
- Why does (0 == ‘Hello’) return true in PHP?
- How to use Imagick to merge and mask images?
- How to display PHP errors in code output?
- session_start() takes VERY LONG TIME
- Set character set using MySQLi
- Using curl in php with client certificate and private key in separate files
- Generate download file link in PHP [duplicate]
- Send FCM messages from server side to android device
- Connecting to websocket with PHP client
- How to remove an HTML element using the DOMDocument class
- fwrite() and UTF8
- Merge two PNG images with PHP GD library
- how to execute mysql command DELIMITER
- Skip Checkout in Magento for a downloadable product
- Add a fee to an order programmatically in Woocommerce 3
- Replace woocommerce_add_order_item_meta hook in Woocommerce 3.4
- Is it possible to execute PHP with extension file.php.jpg?
- Conditionally add associative element to array
- PHP Get Content of HTTP 400 Response
- php in background exec() function
- jQuery Mobile: Sending data from one page to the another
- Unit Test Laravel’s FormRequest