Solved

Keep-alive browser event and coding one with JavaScript under Cold Fusion

Posted on 2003-12-04
4
257 Views
Last Modified: 2010-04-07
Using the JavaScript functions imbedded within Cold Fusion, I have several cases where a seperate browser window is called, opened, and presented to the user. The second browser window allows the user to work with whatever functions/applications are part of the new window.

The problem with this approach is that the original or sending browser session does not mainatain an 'active-state' and will therefore time-out based based on the pre-defined variables (based on business and security rules) that are required for logging-off an 'in-active' browser session.

My idea to control this is to somehow create a 'keep-alive' event that will stay in constant communication with the sending browser session and will keep it active so long as the user is working or active within the second browser window. This is necessary because the user's original or 'sending' browser session is password/userID protected. Obviously, if the user is working away in the second window that was called by the Javascript event imbedded within the Cold Fusion page of the 'sending' event, then the original session will time-out, log-off and require the user to log back into a new secure session.

I need and event(s) that can either suspend the time out activity of the first browser session until focus returns OR keep sending back an event that will make the sending browser window 'think' it is still active?
0
Comment
Question by:edwill
4 Comments
 
LVL 25

Accepted Solution

by:
James Rodgers earned 500 total points
ID: 9885947
as in your previous post at

http://www.experts-exchange.com/Web/WebDevSoftware/ColdFusion/Q_20816604.html

try this

in the child window what data is displayed?

if the data will not change after the intial load yopu could use meta refresh to keep reloading the window every x number of seconds

<meta http-equiv="Refresh" content="20;URL=">

and set the url onloading the window

you can also have in the child window

<script>
   function checkparent(){
     if(window.opener.closed){
          this.close();    
      }
     setTimeOut("checkParent",500);
   }
  setTimeOut("checkParent",500);
</script>

this way if the parent closes the child wil close also
0
 
LVL 4

Expert Comment

by:kssaran
ID: 10738638
I am not sure if you are talking abt the session with Server should be kept alive. If you so, what you can do is write one XMLDOM Object based javascript function, which will just make a request to the web server on a periodic basis. You can make it to function for every 1000 ms using setTimeOut function
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Advice needed on CMS/coding platform 9 59
New Website 15 30
HTML Editor to Choose? (2015) 13 82
USPS CityStateLookup question 3 79
When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
Introduction In this tutorial, I'll explain how to create an animated progress meter in a wireframe prototype developed using Axure RP 7.0 - a leading prototyping tool for designing web sites and software. (For more information about Axure and gett…
The purpose of this video is to demonstrate how to make a WordPress Site faster and smaller in size by cleaning up the database. This will be demonstrated using a Windows 8 PC. Plugin WP Optimize will be used. Go to your WordPress login page. T…
The purpose of this video is to demonstrate how to set up the permalinks on a WordPress Website. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php : Go t…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question