Solved

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

Posted on 2003-12-04
4
256 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

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
How to burn dual layer DVD using Encore CS3 8 143
What is the Best Web Design Tool 1 55
Ezidebit payment gateway 5 90
Collapseable list of URLs. 10 114
When deciding to adopt any help desk solutions many factors should be explored before taking decisions. This will change from business to another but in general there are some kind of rule of thumb. Here are some quick tips: Do we need only ticket…
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…
The purpose of this video is to demonstrate how to manually back up a WordPress Database. This will be demonstrated using a Windows 8 PC. The Host used will be IPage.com Log into your Hosting account. IPage will be used for demonstration : Locat…
The purpose of this video is to demonstrate how to integrate Mailchimp with Facebook. This will be demonstrated using a Windows 8 PC. Mailchimp and Facebook will be used. Log into your Mailchimp account. : Click on your name. Go to Account Setti…

863 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now