NetTalk Central

Author Topic: Login form message when session time out occurs  (Read 2788 times)

alex.kolaric

  • Full Member
  • ***
  • Posts: 151
  • Do it or do not, there is no try
    • View Profile
    • Email
Login form message when session time out occurs
« on: October 29, 2008, 06:10:15 AM »
Hi,

I recently got outsourcing contract job which includes developing of web portion of application using NetTalk web server. I went through all the NetTalk documents and examples on my employer's workstation and I understood most of the things (only the time will show how small my knowledge is  :) ) So here is one question.

I created IndexPage so it has two body options depending on GetSessionLoggedIn() condition. In case when I'm not logged I'm initially showing login page, and when I'm logged I show another body which doesn't contain embeded login page <!-- Net:LoginForm -->. Everything works well, but there is one thing I need. When session expires each option I select sends me to login form as it should, but I would like to show text line on the login page saying that I'm redirected to the login page cause session expired. This text should be hidden when I logout via regular Logout button, or initiate session from the browser address line.

Any suggestions?

thanks,
Alex

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11193
    • View Profile
Re: Login form message when session time out occurs
« Reply #1 on: October 30, 2008, 01:45:22 AM »
Hi Alex,

In the login form you can test to see if the form is in "chained" mode. Ie if the user was "going to a browse" but needed to login instead, then the Value "ChainTo" is set. At the top of the login form the sessionvalue
'ProcedureName_ChainTo' is then set.

So you can include a "Display" field on the form, which is only included if the Session Value is set. Also the name of the procedure you are going to is in ChainTo.

Cheers
Bruce

alex.kolaric

  • Full Member
  • ***
  • Posts: 151
  • Do it or do not, there is no try
    • View Profile
    • Email
Re: Login form message when session time out occurs
« Reply #2 on: October 30, 2008, 03:55:50 AM »
Hi Bruce,

thanks for quick answer. I had no doubt you would come up with a solution. It would be great if some of these "hidden treasures" could become part of the documentation.

Best regards,
Alex