Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: ASP.NET 3.5 Website Programming Problem Design Solution
This is the forum to discuss the Wrox book ASP.NET 3.5 Website Programming Problem Design Solution by Chris Love; ISBN: 978-0-470-18758-6
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 3.5 Website Programming Problem Design Solution section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 13th, 2009, 05:03 PM
Authorized User
 
Join Date: Aug 2008
Location: , , .
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default Missing Log-in Box UserControl (?)

I don't see a Log-in Box User Control in the C# edition. Am I missing something? Is the LogIn box somewhere else?

I can find a Log-in section on the master page but its not even remotely similar to the log-in page in the page.

I see there is a LogInView tool in the tool box.

I got it - I'm supposed to supply it - I guess (?)

Last edited by Cort; December 13th, 2009 at 05:51 PM..
  #2 (permalink)  
Old December 13th, 2009, 10:25 PM
Authorized User
 
Join Date: Dec 2008
Location: London
Posts: 50
Thanks: 1
Thanked 5 Times in 5 Posts
Default

from the toolbox, expand the Login section you should see Login control there.

just double click an aspx file and switch to design mode and drag and drop the control.

Thanks
  #3 (permalink)  
Old January 13th, 2010, 07:57 AM
Authorized User
 
Join Date: Mar 2008
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default I'd like to know where should I put this control

Hello everybody,

I'd like to know where should I drag Login Control to, or I need to create user control by my self with loginview inside it. What am I supposed to do?

Thanks,
Mike
  #4 (permalink)  
Old January 14th, 2010, 08:00 AM
Authorized User
 
Join Date: Jul 2008
Location: , , .
Posts: 29
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to docluv
Default The Login Dlg is markup at the bottom of the Master Page

scroll to the bottom of the Master Page:

Code:
 
    <div id="LoginDlg">
        <div id="dLoginError" />
        <div id="AnonymousView">
            <img src="~/images/lock.gif" runat="server" hspace="5" vspace="12" align="left" alt="Login to the Beer House." />
            Username:
            <input id="txtUsername" type="text" onkeypress="ValidateLoginValues();" /><br />
            Password:
            <input id="pwdPassword" type="password" onkeypress="ValidateLoginValues();" /><br />
            <input id="chkRememberMe" type="checkbox" />Remember Me<br />
            <input id="btnCancel" type="button" value="Cancel" /><input id="btnLogIn" type="button"
                value="Login" /><br />
            <a href="~/Register.aspx" runat="server" class="LoginDialog">Register</a>&nbsp;
            <a href="~/PasswordRecovery.aspx" runat="server" class="LoginDialog">Retrieve
                Password</a><br />
            <div id="dOpenId">
                Login with your OpenId.<br />
                <asp:TextBox runat="server" ID="txtOpenId" class="openid_identifier_dlg" />
                <asp:Button runat="server" ID="btnLoginOpenId" Text="Go" />
            </div>
        </div>
        <div id="LoggedInView" style="display: none;">
            Logged in.<br />
            <input id="btnLogOut" type="button" value="Log Out" />
        </div>
    </div>
__________________
http://Professionalaspnet.com
  #5 (permalink)  
Old January 18th, 2010, 06:11 AM
Authorized User
 
Join Date: Mar 2008
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Thanks a lot, docluv!

Thanks a lot, docluv!

Allon
  #6 (permalink)  
Old January 18th, 2010, 12:16 PM
Authorized User
 
Join Date: Mar 2008
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Login box Creation

I'd like to know what should I do with the code in pages 184-185. My question is if I have to create the login box by myself, or should I add this code to some user control which created by the author.

Thanks in advance, and have a nice day
Allon
  #7 (permalink)  
Old January 18th, 2010, 01:15 PM
Authorized User
 
Join Date: Jul 2008
Location: , , .
Posts: 29
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to docluv
Default

There is not login control to add, it is just markup included in the MasterPage. Therefor it is available on all pages in the site. So when you click the Login link it is invoked.
I am not where I have access to the book, so I will have to wait till I get home tonight to check those pages. But if I remember right there is still a Login.aspx page that was left unchanged from the 2.0 version since that control did not change. It is displayed if you try to directly access content that is restricted.
__________________
http://Professionalaspnet.com
  #8 (permalink)  
Old January 19th, 2010, 02:25 AM
Authorized User
 
Join Date: Mar 2008
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Little note about p. 184-185

First of all - thanks a lot for your time, docluv.

I'll wait till you'll have access to the book. Another thing that made it a little bit confusing to me, is that I thought that I should add this code to the master page (but I was wrong), and then I realized, that this code (in pages 184-185), is very alike the code we can find in accessdenied.aspx (beside the part which starts with <LoggedInTemplate>). I know there is no connection between these two snipets, but still, it was strange for me to find the same code, in two different modules.

Again, thanx a lot.
Allon
  #9 (permalink)  
Old January 19th, 2010, 09:35 AM
Authorized User
 
Join Date: Jul 2008
Location: , , .
Posts: 29
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to docluv
Default

So I looked at the pages you referenced. Yes you are right, this is the code on the AccessDenied.aspx page. This is the page a user is 302 from a page they are not authentected to view, allowing them to login to view the page.
__________________
http://Professionalaspnet.com
  #10 (permalink)  
Old January 20th, 2010, 11:24 AM
Authorized User
 
Join Date: Mar 2008
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Didn't understand what 302 is connected to

Hi, docluv

Is your answer connected to 301 Redirects? Even though it is, I didn't understand what you ment.

Have a good day,
Allon
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to log to server's event log LenexaKS Access VBA 4 March 11th, 2008 12:49 PM
Can't get Log to write the Log.txt file jnbutler BOOK: Professional XNA Game Programming: For Xbox 360 and Windows ISBN: 978-0-470-12677-6 3 July 31st, 2007 04:04 AM
Missing options in choose data source dialog box kuznickic C# 2005 1 May 23rd, 2006 05:35 PM
AppException Class -Log Error to Event Log bekim BOOK: ASP.NET Website Programming Problem-Design-Solution 7 December 7th, 2004 01:01 PM
Usercontrol, .NET, Combo Box and UITypeEditor buczma VB Components 0 March 24th, 2004 11:32 PM



All times are GMT -4. The time now is 12:35 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.