Re: Problem with session time out

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Craig Deelsnyder (cdeelsny_at_no_spam_4_meyahoo.com)
Date: 06/26/04


Date: Sat, 26 Jun 2004 14:32:20 -0500

On Sat, 26 Jun 2004 13:41:51 +0800, Alex <xzvi0r@hotmail.com> wrote:

> Hi
> I am currently working on a project and i happened to encountered a
> problem
> which is very pricky.
>
> I have used formsAuthentication in my project. Manually codes an
> authenticationTicket. And now i realise a problem which has something
> to do
> with session expiry. My project includes popups of windows. And i
> realise
> that when my session expire, the javascript link on the parent window
> will
> still open up the child window and the redirection to the login page was
> done on the pop up instead. But i would like to redirect on the parent
> window instead of the popup window.
>
> Any help would be appreciated.
> Thanks
>
>

All I can say is somehow track whether the login page is displayed in a
popup window, then redirect the window.opener to the login page and close
the popup window (this all happens in the popup window's Javascript,
meaning in login.aspx, e.g.).

Perhaps the easiest way to tell if your popup was opened by one of your
links is to add some querystring arg (like &window=popup) and then
login.aspx can check for this and do the above logic.

But you have to do this yourself; your link is popping up via Javascript
so there's no way for the server to tell the browser what has happened.

-- 
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET


Relevant Pages

  • Re: PHP Session in new window
    ... In the form that submits to the popup window, ... Create a hidden field in my form with the session ID ... >> Problem is on return (successful transaction etc) I cannot access the ...
    (alt.php)
  • Re: Frontpage query
    ... You need to select a target other than the default target which is probably ... To open your flash in a popup window while keeping your viewers on the ...
    (microsoft.public.frontpage)
  • Re: Why so much emotion about IWB 2.0.5? was re: other stuff and re: IBM Web Browser v2.0.5 is here
    ... It looks like IBM has fixed some of the problems reported as fixed in Mozilla 1.7.5. ... MFSA 2005-13 "Window Injection Spoofing" is still there. ... If you don't have popups blocked, the spoofed window does open, but it opens as a popup window so it doesn't seem very serious since popup windows can display just about anything their creator wants, anyway. ... You could be a victim in this way but it looks unlikely since there would first have to be the malicious website with the bad link and then you would have to be pretty 'unwise' to enter any significant data into ...
    (comp.os.os2.apps)
  • Re: targeting main window from popup
    ... > may just use the popup as its own target, ... opener and didn't close the popup window as expected). ... The javascript works fine but doesn't actually run the PHP script as ...
    (comp.lang.javascript)
  • Hiding Access
    ... My client wanted a small form which displayed stats to reside on the top of ... Access disappears but also the popup window I want to display. ... Global Const SW_SHOWNORMAL = 1 ...
    (microsoft.public.access.forms)