Logo

Session Timeout Demo

After a set amount of time(10 seconds set for demo), a dialog is shown to the user with the option to either log out now, or stay connected. If log out now is selected, the page is redirected to a logout URL. If stay connected is selected, a keep-alive URL is requested through AJAX. If no options is selected after another set amount of time, the page is automatically redirected to a timeout URL.


            var KTSessionTimeoutDemo = function() {
                var initDemo = function() {
                    $.sessionTimeout({
                        title: "Session Timeout Notification",
                        message: "Your session is about to expire.",
                        keepAliveUrl: "HOST_URL + "/api/session-timeout/keepalive.php",
                        redirUrl: "#",
                        logoutUrl: "#",
                        warnAfter: 3000, //warn after 5 seconds
                        redirAfter: 35000, //redirect after 10 secons,
                        ignoreUserActivity: true,
                        countdownMessage: "Redirecting in {timer} seconds.",
                        countdownBar: true
                    });
                }

                return {
                    //main function to initiate the module
                    init: function() {
                        initDemo();
                    }
                };
            }();

            jQuery(document).ready(function() {
                KTSessionTimeoutDemo.init();
            });
            

Notifications 24 New

Quick Actions finance & reports

User Profile 12 messages

Recent Notifications
Stockholm-icons / Home / Library Created with Sketch.
Another purpose persuade Due in 2 Days
+28%
Stockholm-icons / Communication / Write Created with Sketch.
Would be to people Due in 2 Days
+50%
Stockholm-icons / Communication / Group-chat Created with Sketch. -27%
Stockholm-icons / General / Attachment2 Created with Sketch.
The best product Due in 2 Days
+8%
System Messages
Top Authors Most Successful Fellas
+82$
Popular Authors Most Successful Fellas
+280$
New Users Most Successful Fellas
+4500$
Active Customers Most Successful Fellas
+4500$
Bestseller Theme Most Successful Fellas
+4500$
Notifications
Stockholm-icons / Home / Library Created with Sketch.
Another purpose persuade Due in 2 Days
+28%
Stockholm-icons / Communication / Write Created with Sketch.
Would be to people Due in 2 Days
+50%
Stockholm-icons / Communication / Group-chat Created with Sketch. -27%
Stockholm-icons / General / Attachment2 Created with Sketch.
The best product Due in 2 Days
+8%
Customer Care
Reports
Memebers
Stockholm-icons / Navigation / Up-2 Created with Sketch.

Select A Demo