Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7002645
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T20:57:19+00:00 2026-05-27T20:57:19+00:00

Most of my ASP.NET website is accessible to an anonymous web users. However there

  • 0

Most of my ASP.NET website is accessible to an anonymous web users. However there are a few pages that I require authentication before I allow access. I control this via the web.config:

<authorization>
    <allow users="*"/>
</authorization>

Currently my logon.aspx file is generic, but I would really like to include instructions telling the user why he was redirected to the logon page. Something like:

Before you can volunteer for a task, please logon so the system can identify you.

OR

You’ve attempted to edit an event. The system only allows Administrators to do this. Please logon so we can verify you are an administrator of this event.

The instructions on the logon page would depend on what the user was attempting prior to the forms authentication redirect.

My problem is how can the logon page determine what action was taken? Is there anyway to pass a custom querystring to the logon page? I guess I could decode the ReturnUrl and use that to try an determine what instructions to display. However that approach just feels….dirty. I don’t like the logon page having a dependency on the URL names of other pages in the system.

Any suggestions?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T20:57:20+00:00Added an answer on May 27, 2026 at 8:57 pm

    You could use the HttpRequest.UrlReferrer Property to find out what was the user intention.

    Or you could set a QueryString / Session variable before redirecting and use it to display some message.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an ASP.NET website where most of the pages are generated and published
I got a ASP.NET MVC website that is working fine in most desktop browers,
I'm working on a ASP.NET (C#) site that pulls most of its data from
I am learning ASP.NET MVC now a days and I have found that most
I've got an issue with an ASP.Net MVC project in that on most of
Most of my company's web programming background is PHP, so ASP.NET MVC was a
In our system most of the code is in an asp.net (2.0) web site,
I'm trying to ensure that visitors of my ASP.NET MVC website always have the
I have an ASP.NET website that I built that has grown considerably in size
OK, here is the question, I have a asp.net website, there is an aspx

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.