• Page refresh when there is no activity

    $(function () { var timer, updateContent; function resetTimer() { if (timer) { window.clearTimeout(timer); } timer = window.setTimeout(updateContent, 30000); } updateContent = function () { resetTimer(); $.get('test.php', function (data) { $('#content').html(data); }); }; resetTimer(); $(document.body).on('mousemove keydown', resetTimer); });
  • 0 comments:

    Post a Comment

    FAVOURITE LINE

    To steal ideas from one is plagiarism. To steal from many is Research.

    ADDRESS

    Mumbai , Maharashtra

    EMAIL

    shikha.pathak6@gmail.com
    shikha.the.swt.pari@gmail.com

    Skype

    shikha_pari