Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Password protected web page

Posted on 2008-10-16
3
Medium Priority
?
159 Views
Last Modified: 2010-04-21
i m developing a web site with members login. in my default page their is a login and password , after entering username and password the user can access the page which is redirect according to username and password, now suppose if any user make that redirected page as home page or bookmark that page than he can able to skip that login/default page. I want the script in asp.net that the user can only access that redirect page through correct login and password and can't able to open that page directly by skiping default page.
0
Comment
Question by:cbpandya
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 4

Accepted Solution

by:
sijishJohn earned 750 total points
ID: 22729917
0
 
LVL 2

Assisted Solution

by:EruditeMonkey
EruditeMonkey earned 750 total points
ID: 22730175
The forms authentication mentioned above is the best solution but if you want something quick and simple you could try this:
On the login page, once the password has been checked add a session variable:
Session("LoggedOn")=True
Then, on each of the pages you want to secure add this in page_load

If Session("LoggedOn") Is Nothing Then Response.Redirect("Default.aspx")
 
0
 

Author Closing Comment

by:cbpandya
ID: 31506678
Can you explain me

"Session("LoggedOn")=True

Then, on each of the pages you want to secure add this in page_load


If Session("LoggedOn") Is Nothing Then Response.Redirect("Default.aspx")

because i have around 11 - 15 fixed different users for my web site to access their particular pages for all 11 - 15 users, can you tell me how i can set each session for each users and how ?
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

When it comes to write a Context Sensitive Help (an online help that is obtained from a specific point in state of software to provide help with that state) ,  first we need to make the file that contains all topics, which are given exclusive IDs. …
This article discusses how to create an extensible mechanism for linked drop downs.
In this Micro Tutorial viewers will learn how to create navigation buttons that change on rollover, using CSS (Continuation of the CSS Image Sprite tutorial) Create a parent ID for all the list items       - Specify position: absolute and display: block…
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…

670 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