Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > Splitter > Session Timeout and RadPane
RadControls for ASP.NET are no longer supported (see this page for reference). In case you have inquiries about the Telerik ASP.NET AJAX controls, post them in the pertinent ASP.NET AJAX forums.

Session Timeout and RadPane

Feed from this thread
  • Posted on Jun 4, 2007 (permalink)

    My page is split with one RadSplitter.  My navigation is on the left using a RadPpanelBar inside a RadPane and the main body on the right contains a RadPane.

    I am using FormsAuthentication.  However, when a session times out both panes display my login form.  If a user clicks Log Off in the RadPane on the right, only it displays the login form.

    Neither of these behaviors is desirable.  If a user logs off or a session times out, I want the parent page to load the login form.  To accomplish this I put this function in the onLoad of the Login page:

    <script type="text/javascript">  
            function logon(){  
                try{  
                    if (self.parent.frames.length != 0)  
                    self.parent.location=document.location;}  
                catch (Exception) {}}  
    </script> 

    This seems to work.  The login page checks to see if it is in a frame and if so breaks out.  Now the problem is when the user successfully logs back in it only loads the content of the right pane in the whole window.  The parent page isn't loaded, only one of the content panes.

    Surely others of you have dealt with this.  What's the solution?

  • Tsvetie Tsvetie admin's avatar

    Posted on Jun 7, 2007 (permalink)

    Hi Carla,
    This happens, because the document.location does not return the raw url. You can change that, by assigning directly the name your login page:

    <script type="text/javascript">     
        function logon()  
        {       
            if (self.parent.frames.length != 0)     
            self.parent.location="Login.aspx";  
        }     
    </script>  


    Greetings,
    Tsvetie
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center

  • Kiran avatar

    Posted on Feb 23, 2009 (permalink)

    Hello Tsvetie,

    Your suggestion works like a charm!!. Thanks a lot.

    But i need one more favor from you. See i have  the same UI Design as Carla. But what happens when it logs out for fraction of second it shows Login Screen on clicked Pane e.g. if i clicked on left pane and session expired then it will show me a login page for a fraction of second [If Network is too slow then user can see the difference] under Left pane. Which i don't want.

    What i was thinking that we should call "logon" js function before onload of body means before it renders the content on page. If you/Carla have achieved this thing then it would be great if you share it with me.

    Thank you,

    Regards,
    Kiran Patil

  • Mac P Intermediate avatar

    Posted on Jun 16, 2011 (permalink)

    i have same problem.

    Kiran,

    Did you find the solution to avoid flicker. I mean redirect in event before page load?

  • Niko Niko admin's avatar

    Posted on Jun 17, 2011 (permalink)

    Hello Mac,

    Unfortunately there is no straight-forward solution to this issue. Generally you will have to implement a security solution(login/logout are part of the security of a system), such that you will be able to know in the page that contains the splitter, not the page that is loaded within the splitter, if the session has expired or not and from there to redirect to the Login page. Currently the splitter page is loading and barely then the internal page, in the content pane is starting to load, therefore it is already late to implement any logic within the content pane's page.

    Hope this will make things a bit clearer to what is going wrong and how to fix it.

    Greetings,
    Niko
    the Telerik team

    Consider using RadControls for ASP.NET AJAX (built on top of the ASP.NET AJAX framework) as a replacement for the Telerik ASP.NET Classic controls, See the product support lifecycle here.

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET > Splitter > Session Timeout and RadPane