Skip to Content
Beginning ASP.NET 3.5: In C# and VB
book

Beginning ASP.NET 3.5: In C# and VB

by Imar Spaanjaars
March 2008
Intermediate to advanced content levelIntermediate to advanced
766 pages
21h 15m
English
Wrox
Content preview from Beginning ASP.NET 3.5: In C# and VB

6.3. Themes

So far you've seen how to create a master page to define the global look and feel of the pages in your site. You also saw how to centralize the behavior of your pages by using a central base page. There are, however, more ways to influence the look and feel of your site: themes and skins. Skins will be dealt with later in the chapter, as they are a part of themes, which need to be discussed first.

A theme is a collection of files that define the looks of a page. It can include skin files, CSS files, and images. You define themes in the special App_Themes folder in the root of your website. Within this folder you need to create one or more subfolders that define the actual themes. Inside each subfolder, you can have a number of files that make up the theme. Figure 6-12 shows the Solution Explorer for a web site that defines two themes: Monochrome and DarkGrey.

Figure 6-12. Figure 6-12

A link to each CSS file in the theme folder is added to your page's <head> section automatically whenever the theme is active. You'll see how this works later. The images in the themes folder are referenced from the CSS files. They can be used to change common elements of the web site, such as background images, or images used in bulleted lists or navigation lists.

To create a theme, you need to do the following:

  • Create the special App_Themes folder if it isn't already present in your ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Beginning ASP.NET 4: in C# and VB

Beginning ASP.NET 4: in C# and VB

Imar Spaanjaars
Professional ASP.NET 3.5 SP1 Edition: In C# and VB

Professional ASP.NET 3.5 SP1 Edition: In C# and VB

Bill Evjen, Scott Hanselman, Devin Rader

Publisher Resources

ISBN: 9780470187593Purchase book