Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 4.5.1 : in C# and VB
This is the forum to discuss the Wrox book Beginning ASP.NET 4.5.1: in C# and VB by Imar Spaanjaars; ISBN: 978-1-118-84677-3
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 4.5.1 : in C# and VB section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 18th, 2016, 02:23 PM
Authorized User
 
Join Date: Aug 2014
Posts: 34
Thanks: 3
Thanked 0 Times in 0 Posts
Default Chs. 6&7 - Master Pages and Sitemap TreeView

Happy Holidays and TIA:

I use a master page (Frontend.mater) in my aspx site that consists of a tree view menu. My problem is that one of my pages is my login page to the site which currently includes this master page (template). My sense is that my menu to the rest of my pages should only be seen AFTER a verified login.

Is there a way that I can: 1) Hide an entire treeview menu for this login page while keeping other controls, css, and scripts for the page. 2) Is it a matter of creating a second Frontend.master file for the login page with an empty <nav> section? 3) Other considerations?

Thanks, Cliff
 
Old December 18th, 2016, 02:55 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

Checkout Chapter 16 and look for the LoginView control, introduced on page 600.

Cheers,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
 
Old December 20th, 2016, 03:15 PM
Authorized User
 
Join Date: Aug 2014
Posts: 34
Thanks: 3
Thanked 0 Times in 0 Posts
Default Hiding TreeView on login page

Hi and TIA:

I have a treeview menu as part of a series of aspx pages. On all of the pages I want the treeview menu to show except for the login page.

I have accomplished making the treeview menu to not show on the login page by using

TreeView1.Visible = false;

in my Frontend.master.cs page under Page_Load.

My question has to do with the fact that now when I load the login.aspx page a "tiny horizonal slit" appears where the menu "begins" at the top left side of the page. This seems to be a type of "container" that is showing empty, but after reading and looking I am unable to completely delete and trace of the treeView menu on the login page.

Any ideas would be greatly helpful Thanks, Cliff
 
Old December 21st, 2016, 04:27 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Could this be the container <nav> element or maybe the SiteMapPath showing up?

Try using your browser's developer tools (like FireBug on FireFox) and analyze the HTML. Try removing (or hiding by adding a CSS style of display: none) to the elements you see until they go away. Then you know what's causing it and make it go away server side.

Cheers,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to add Meta Tags to Master Pages/Content Pages Pdesignz BOOK: Beginning ASP.NET 4 : in C# and VB 9 May 31st, 2012 07:08 AM
General question - Master Pages, Base pages, templates and OOP. flapjack BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 2 May 1st, 2010 09:33 AM
TreeView and SiteMap Node Order robzyc ASP.NET 1.0 and 1.1 Basics 0 May 19th, 2008 04:27 AM
Master Page Control/Web.Sitemap Questions kwilliams ASP.NET 2.0 Professional 2 January 14th, 2007 09:32 PM
Master pages &server control ID - asp.net 2.0 tech user C# 2005 1 August 3rd, 2006 04:31 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.