Git Product home page Git Product logo

Comments (19)

JillElaine avatar JillElaine commented on July 20, 2024

What is the value of your 'redirectUrl' variable?

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

Logout page URL of my application.
I have three master pages and instead of adding script on all pages. I have created separate JS file and included script in JS file. Then I gave reference of this JS file in Master page.
I have given reference of Jquery Idle time out script and store.Js in master page.
ThanksAmit Joshi

Date: Mon, 4 Jan 2016 18:51:36 -0800
From: [email protected]
To: [email protected]
CC: [email protected]
Subject: Re: [jquery-idleTimeout] Session Time out dialog box dosen't disappear (#23)

What is the value of your 'redirectUrl' variable?


Reply to this email directly or view it on GitHub.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

image

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

When Click on Logout now it is not redirecting. I have added script on master page under document.load.

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Please replace the jquery-idleTimeout script with the jquery-idleTimeout-for-testing.js on your site, and watch the console debug log. One way to do this is to use Mozilla Firefox with the Firebug web developer add-on: http://getfirebug.com/ The console log should tell you exactly where the script is failing. Is it possible that your configuration script in (document).ready is not available on all pages?

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

I don't want to put this script on all pages. I have created separate Js file. But I will check with testing.js file.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

Logout page has master page reference. on Master page on document.load I have idleTimeout script. so Logout page page_load method is getting called again and again.

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

What I meant was, "Is it possible that your configuration script in (document).ready is not available on all pages where you need it to be available?"

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Sounds like you have loaded the script multiple times? It should be loaded only once.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

Yes because I have three master pages and some of the page don't have master page reference. so I have to add the script on that page as well.

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Check on each page that the script is loaded only once. The firebug add-on will show the loaded scripts for each page.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

0:2- NAN value in dialog box shows because of this?

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Yes, the dialog box would normally not be shown when the page properly redirected. The countdownDisplay function just continues counting down as long as the script is still loaded. Typically the idleTimeout script would be unloaded on the redirect page, since the user was logged out.

If there was a case where someone wanted the dialog box to remain visible and not have the page redirect, then they could rewrite the countdownDisplay function to display "0" and exit that function once zero had been reached. One would also want to unload the idleTimeout script in that case.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

But in my case Logout page page_load event is getting called multiple times and it is not getting redirected.

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Yes, you need to change your page so that the idleTimeout script is loaded only once. It should not be called multiple times. This is a problem with your site, not a problem with the idleTimeout script. I am not sure how to help you with the set up of your site and how you load your scripts.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

My issue is resolved. Thanks for your help.

from jquery-idletimeout.

joshiamit24 avatar joshiamit24 commented on July 20, 2024

one question. This ideal time script internally uses local storage to store time?

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

Glad to hear you solved your issue. If you read the heavily commented code in jquery-idleTimeout-for-testing.js, you can learn much of the functionality. Basically, the idleTimeout script uses local storage (via Marcus Westin's store.js) to store the current time of the last detected activity (eg: mouse move) in the variable, idleTimerLastActivity. See below.

Local storage is also used to store the value of other variables that need to be shared among windows and tabs.

    startIdleTimer = function () {
      console.log('start startIdleTimer');
      stopIdleTimer();
      store.set('idleTimerLastActivity', $.now());  // this is the reference to local storage
      checkIdleTimeoutLoop();
    };

from jquery-idletimeout.

JillElaine avatar JillElaine commented on July 20, 2024

User configuration issue. Resolved.

from jquery-idletimeout.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.