[Last Call] Learn how to a build a cloud-first strategyRegister Now


Triggering event when member returns

Posted on 2012-09-20
Medium Priority
Last Modified: 2012-09-22
I know I can detect when a person logs in via username/password but how can I detect when a person returns to the site (any page on the site) when they've checked the "remember me" box?  I need to fire an event or something so that I can do some stuff one time when a person comes to the site and is logged in.

Any ideas?
Question by:jglazer63
  • 2
  • 2
LVL 83

Expert Comment

ID: 38418787
You need to check the URLReferrer on the Request object to see if its empty and check the Cookies collection.

Author Comment

ID: 38418799
Can you expand on this a little?
LVL 83

Accepted Solution

CodeCruiser earned 2000 total points
ID: 38418898
If you check Request.URLReferer, it would contain URL of previous page. If its empty, it means user directly came to your site. If user was able to access the page directly without going to login page then it could indicate that cookie is used for authentication.

Author Closing Comment

ID: 38425341

Featured Post

Veeam and MySQL: How to Perform Backup & Recovery

MySQL and the MariaDB variant are among the most used databases in Linux environments, and many critical applications support their data on them. Watch this recorded webinar to find out how Veeam Backup & Replication allows you to get consistent backups of MySQL databases.

Question has a verified solution.

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

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
Integration Management Part 2
Suggested Courses

825 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