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 March 29th, 2017, 09:54 PM
Authorized User
 
Join Date: Mar 2017
Posts: 55
Thanks: 12
Thanked 0 Times in 0 Posts
Default Ch 6 - Themes vs. No Themes

I want to design my website with a consistent look, including images in the header. Is a theme (assuming no overriding desired) the best idea, or are there other ways to simply customize my master page for a consistent look throughout that includes images?

In other words, could I just add an image to the <header> tag in the master page. Or have the entire header contain a background image.

Just curious - would a theme be the better way to go, or is it an "either-way" decision?

Also, at Chapter 6, page 220, bullet point 7 - I added the code to my config file:

Code:
 <pages theme="MainTheme" styleSheetTheme="MainTheme" />
but my master page still doesn't show the style(s) in Design View. Although it works in the browser.
 
Old April 2nd, 2017, 03:25 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Instead of a theme, you can also just use standard CSS files linked to from within your master page. With a theme it's easy to switch between two completely different layouts. if you don't need that, you can just use standard CSS, images and so on.

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 April 2nd, 2017, 06:00 PM
Authorized User
 
Join Date: Mar 2017
Posts: 55
Thanks: 12
Thanked 0 Times in 0 Posts
Smile Themes vs. No Themes

Thanks! Did you have any feedback regarding the last part of my question? Using styleSheetTheme in the config file to show the styles in design view?
 
Old April 3rd, 2017, 04:38 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Nope, not sure why it wouldn't work. Are you sure you made the change to the web.config in the root of the Solution Explorer in Visual Studio? Which folder are you opening as the web site in VS?

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 April 3rd, 2017, 09:31 AM
Authorized User
 
Join Date: Mar 2017
Posts: 55
Thanks: 12
Thanked 0 Times in 0 Posts
Default styeSheetTheme attribute in config file

Thanks! It's working now. I am not sure what correction I made, but one thing that I recently did was to remove a root folder, "Site", in my website directory. I know I could have kept this folder, but I would have needed to make changes throughout (as I copied and pasted over various files from the wrox downloads and there was no "Site" folder in these).

So maybe after doing this - I fixed the issue. Needless to say, it is now working!

PS: And after all that, I'm probably going to scrap the whole "Theme" concept anyway. I don't want to allow any dynamic switching of themes in any current websites I may be working with. But...it's nice to know that I "can" if needed!





Similar Threads
Thread Thread Starter Forum Replies Last Post
Ch. 6 browser showing combination of the two themes C# only, VB is fine tmulher BOOK: Beginning ASP.NET 4.5.1 : in C# and VB 2 May 15th, 2015 08:51 AM
Ch 6 Stuck on the DDL for Themes Aristide BOOK: Beginning ASP.NET 4.5 : in C# and VB 6 April 1st, 2014 10:37 PM
Themes SP2010Dude BOOK: Beginning ASP.NET 4 : in C# and VB 1 September 17th, 2010 02:01 AM
Use Themes? the.pi.man ASP.NET 2.0 Basics 2 March 7th, 2007 08:44 AM
Themes bmains ASP.NET 2.0 Basics 2 August 2nd, 2004 08:48 AM





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