Chapter 6. Creating Consistent Looking Web Sites

WHAT YOU WILL LEARN IN THIS CHAPTER:

  • How to use master and content pages that enable you to define the global look and feel of a web page

  • How to work with a centralized base page that enables you to define common behavior for all pages in your site

  • How to create themes to define the look and feel of your site with an option for the user to choose a theme at runtime

  • How to create skins to make site-wide changes to control layout

  • What the ASP.NET page life cycle is and why it's important

When you're building a web site you should strive to make the layout and behavior as consistent as possible. Consistency gives your site a professional appearance and it helps your visitors to find their way around the site. Fortunately, ASP.NET 4 and Visual Web Developer 2010 offer a number of great features and tools to implement a consistent design, helping you create great-looking pages in no time.

In previous chapters you learned how to work with VWD, HTML, CSS, and server controls to create your web pages visually. Chapter 5 introduced you to programming in ASP.NET. This chapter is the first that combines these concepts, by showing you — among many other things — how to use programming code to change the appearance of the site.

The next section shows you how to create a master page that defines the general look and feel of a page. The ASPX pages in your site can then use this master page without the need to rewrite the layout. The remaining sections of ...

Get Beginning ASP.NET 4: in C# and VB now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.