[How Do I:] Use Skins with CSS for a Flexible and Maintainable ASP.NET Web Site

by Chris Pels

In this video Chris Pels shows how to create skins for ASP.NET server controls and then incorporate CSS styles to control the appearance of the skinned controls. First, learn how to create a skin for an ASP.NET server control such as a Label that controls the appearance of labels throughout a web site. Next, see how to abstract the definition of the visual appearance for a skin to CSS styles. During this process learn the advantages of having the styling information for a skin in the CSS styles. Then see how to create multiple skins and corresponding styles for a single ASP.NET control such as a Label that can be used to standardize the appearance of certain types of labels throughout a web site. Finally, learn the advantages of applying a CSS style to multiple skins and the ability to apply it to a generic HTML element.

▶ Watch video (29 minutes)