delete session variable when close browser with out logout

Answer Posted / koushikgraj

on unload event in javascript will trigger when the window
is going to close.

we can call a ajax function to clear session

Is This Answer Correct ?    8 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which will check if a function exists?

817


Do you know what is the difference between the include() and require() functions?

711


What is an anti csrf token?

675


Do you know what does $globals means?

795


How to check curl is enabled or not in PHP

851


What is php built on?

714


Write a program to swap two numbers using php.

740


What is the use of die in php?

688


How to get ip address of clients machine?

704


Give the case where we can use get and we can use post methods?

752


Explain how can we increase the execution time of a php script?

705


How big is varchar max?

761


Does php have block scope?

690


How can you tell if a number is even or odd without using any condition or loop?

725


How to set a value in session? How to remove data from a session?

730