JQUERY detect inactive jquery - Net-Raft.com

Welcome aboard! We are happy you are here and wish you good net-raft!




Just a Web Code Solution

detect inactive user using jquery


 501

JQUERY


2

<!DOCTYPE html>
<html>
<head>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>

</head>
<body>

<script type="text/javascript">

$(document).ready(function () {
var idleState = false;
var idleTimer = null;
$('*').bind('mousemove click mouseup mousedown keydown keypress keyup submit change mouseenter scroll resize dblclick', function () {
clearTimeout(idleTimer);
if (idleState == true) {
$("body").text('');
}
idleState = false;
idleTimer = setTimeout(function () {
$("body").text('you are idle!');
idleState = true; }, 5000);
});
$("body").trigger("mousemove");
});

</script>

</body>
</html>


By     Created   
The power of the user (%)
4%



The most helpful JQUERY solutions

plugin get client ip address using jqueryplugin get client ip address using jqueryJQUERY

Click to see more ...

  5.4K     1.3K

How to get client machine name or computer name with jquery?How to get client machine name or computer name with jquery?JQUERY

Click to see more ...

  4.5K     724

plugin detect country jqueryplugin detect country jqueryJQUERY

Click to see more ...

  2.1K     562

show position on google map jqueryshow position on google map jqueryJQUERY

Click to see more ...

  1.6K     386

cookie jquerycookie jqueryJQUERY

Click to see more ...

  1.9K     381

How to detect the version of IE browser using jquery ?How to detect the version of IE browser using jquery ?JQUERY

Click to see more ...

  1.1K     310

plugin convert thousands to K jqueryplugin convert thousands to K jqueryJQUERY

Click to see more ...

  850     258

How to get top, right, left, bottom position of element div using jquery ?How to get top, right, left, bottom position of element div using jquery ?JQUERY

Click to see more ...

  557     206

how to create a jquery plugin for converting date to days ago, month ago and year ago ?how to create a jquery plugin for converting date to days ago, month ago and year ago ?JQUERY

Click to see more ...

  558     199

how to get ip address using jquery ?how to get ip address using jquery ?JQUERY

Click to see more ...

  529     196