I think I used to know how to do this one, but I no longer remember...

When your application times out, you can send the user back to the login page 
with code like the following:

<cfif not Session.LoggedIn>
   <cfif cgi.script_name is not '/Login.cfm'>
      <cflocation url='/Login.cfm'>
   </cfif>
</cfif>

But suppose this happens just when the user is opening a nested window, and the 
login page opens in that window. How do you close the nested window 
automatically and force the login page to open in the main browser window 
instead?

I thought something like the following, placed in Login.cfm, would work:

<script>
if (window != top){
   top.location.href='Login.cfm';
   window.close();
   }
</script>

or maybe something like this:

<script>
if (window != parent){
   parent.location.href='Login.cfm';
   window.close();
   }
</script>

My memory says it was something like the above. But evidently 'top' and 
'parent' have to do with frames. In any case, the above attempts do not do the 
job.

How is this done?

Thanks,

Rip


-------------------------------------------------------------
Annual Sponsor FigLeaf Software - http://www.figleaf.com

To unsubscribe from this list, manage your profile @ 
http://www.acfug.org?fa=login.edituserform

For more info, see http://www.acfug.org/mailinglists
Archive @ http://www.mail-archive.com/discussion%40acfug.org/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------



Reply via email to