473,796 Members | 2,632 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Login Control!!

Hi All, I have a website which allows users to visit anonymously. Throughout
the page I offer a signup link thru which a user can create an account. I
want the user to be redirected to the page on which he working when he
clicked up the signup link (which is create account wizard page )
How to accomplish this?

I know the request.REferea lURl etc...API's but don't know where in the
create account wizard I shud place this?

TIA
Feb 6 '07 #1
2 1195
Hi,

when someone tries to access your secured page, the most probale way you
would be using is on Page_Load you would check if his session value is not
null, in case it is you will redirect him to the login page with appropiate
message. What you can do here is, you can pass the url of the page he has
got redirected from to the login as querystring, and after proper validation
you can redirect him back to that page as you would have the URL,...e.g:-

in your page_load, you would write.......... ...

if (Session["LoginStatu s"] == null){
Response.Redire ct("UserLogIn.a spx?rurl=" +
Server.HtmlEnco de(Page.AppRela tiveVirtualPath ));
}
and in your login page, after validation..... .

if (username and password id valid logic) {
Response.Redire ct(Request.Quer yString["rurl"].toString());
}

Hope this helps.

Rgds,
Bhaskar


"Vai2000" <no****@microso ft.comwrote in message
news:OH******** ********@TK2MSF TNGP05.phx.gbl. ..
Hi All, I have a website which allows users to visit anonymously.
Throughout
the page I offer a signup link thru which a user can create an account. I
want the user to be redirected to the page on which he working when he
clicked up the signup link (which is create account wizard page )
How to accomplish this?

I know the request.REferea lURl etc...API's but don't know where in the
create account wizard I shud place this?

TIA


Feb 6 '07 #2
Thanks, though was looking for some out of the box functionality in asp.net
2.0
"Bhaskardee p Khaund" <bh*********@re diffmail.comwro te in message
news:uY******** ******@TK2MSFTN GP05.phx.gbl...
Hi,

when someone tries to access your secured page, the most probale way you
would be using is on Page_Load you would check if his session value is not
null, in case it is you will redirect him to the login page with
appropiate
message. What you can do here is, you can pass the url of the page he has
got redirected from to the login as querystring, and after proper
validation
you can redirect him back to that page as you would have the URL,...e.g:-

in your page_load, you would write.......... ...

if (Session["LoginStatu s"] == null){
Response.Redire ct("UserLogIn.a spx?rurl=" +
Server.HtmlEnco de(Page.AppRela tiveVirtualPath ));
}
and in your login page, after validation..... .

if (username and password id valid logic) {
Response.Redire ct(Request.Quer yString["rurl"].toString());
}

Hope this helps.

Rgds,
Bhaskar


"Vai2000" <no****@microso ft.comwrote in message
news:OH******** ********@TK2MSF TNGP05.phx.gbl. ..
Hi All, I have a website which allows users to visit anonymously.
Throughout
the page I offer a signup link thru which a user can create an account.
I
want the user to be redirected to the page on which he working when he
clicked up the signup link (which is create account wizard page )
How to accomplish this?

I know the request.REferea lURl etc...API's but don't know where in the
create account wizard I shud place this?

TIA


Feb 6 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
2634
by: clintonG | last post by:
This is an appeal for peer support sent to Microsoft as will be noted in closing. The Login control does not include a Cancel button. The only option is to convert the Login control to a template which is not such a bad thing in itself but it means all other controls in the application must also be converted to templates to maintain a consistent UI. So much for writing 70% less code when foolish morons release a control with no cancel...
1
4539
by: EricRybarczyk | last post by:
I am starting a rewrite of an existing Classic ASP web site in ASP.NET 2.0. The existing ASP application has several types of users, each with a separate login process (separate login page, separate DB tables, etc). For one of these user types, the current application has an additional input field required for login… they have a username, password, and another “location code” field. Please don’t make me explain or justify this…...
1
6986
by: Jeff Lynch | last post by:
I'd like to add the following attributes to the Login control's Login Button to create a CSS rollover effect. How can I access the control's login button from the page's code-behind? LoginButton.Attributes.Add("onmouseover", "this.className = 'buttonsmallover'"); LoginButton.Attributes.Add("onmouseout", "this.className = 'buttonsmall'"); -- Jeff Lynch
3
5792
by: ilockett | last post by:
The background: I have a web app with a simple master page that contains just one content placeholder. I have created a web form that then uses this master page. Within the content placeholder, I have placed a Login control (Login1) and a ValidationSummary control. I have set the ValidationSummary's ValidationGroup property equal to "Login1".
3
2123
by: Bruce | last post by:
I just started the design of an ASP.NET application which accesses one of our custom web services to provide user authentication, among other purposes. I created a log-in page (code below), using the WebControls.Login control. I put a simple label on the page, to display text showing whether the log-in was successful. I populate the Label.Text from within the event handler for the Login control's Authenticate event. But when I run...
5
1922
by: Afshar | last post by:
Hi everybody there, I have a special Login page that wants users to enter 3 passwords rather than a single password. But can't do it with Login control. I tried following scenarios: 1. Put an Login in the page and set its Visible = False instead put my own username and 3 password on the form. Then I checked 2nd and 3rd password seperately and passed username and password to Login control via its Username and Password properties but...
3
1505
by: goot | last post by:
I'm trying to use the login control and have it use the membership provider framework to authenticate users and am having a problem (which i'm sure will turn out to be a stupid mistake on my part)... this is what I have done thus far: Created a database on a sql 2000 server and then used the aspnet_regsql tool to create the membership tables I then modified the web.config as such:
2
4244
by: Sasquatch | last post by:
I'm having trouble creating a simple login page using the asp:login control. I followed some instructions in a WROX book, "Beginning ASP.NET 2.0," and the instructions are very straight forward, but it won't work for me. Here's what I did. 1. Created a new folder named "testlogin" 2. Turned that folder into an application using the IIS properties 3. Created two new web form pages, /testlogin/default.aspx and /testlogin/login.aspx...
3
4342
by: =?Utf-8?B?RHVrZSAoQU4yNDcp?= | last post by:
The majority of pages on our site need authentication (forms auth against the aspnetdb database). I created an '~/auth' folder with its own config file forcing authentication for any pages in the folder. The default.aspx sits in the root folder and just does a Response.Redirect to an ~/auth/home.aspx page. The config forces authentication, which is carried out by ~/pub/login.aspx which has a standard asp:login control. I set up the...
6
8080
by: dan | last post by:
Hi, Could someone please let me know how to center a Login control on a page? Can I use CSS to do that? Thanks, Dan
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look ! Part I. Meaning of...
0
9533
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10461
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10190
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10019
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7555
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupr who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6796
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5447
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5579
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.