Master Page in Asp.Net

 Rate It (3)

One of the great additions to ASP.NET 2.0 is Master Pages. Master Pages help us build a consistent and maintainable UI throughout a site.

A master page can be created to hold those page elements that represent the common look and feel of a website. Various page elements that you might normally have added to each content page (banners, footers, menus, stylesheet links etc...) can instead be placed in the master page.  When a new content page is created, the developer simply needs to link it to an existing master page.  When that content page is rendered, the content page and its associated master page will be "merged" at runtime.  The resulting markup will contain all of the elements from the master page as well as those elements defined in the content page.

Since it is possible for many site pages (or even all site pages) to refer to a single master page, it becomes very easy to create a common look and feel for all pages in a website. It is also possible for a single site to contain multiple master pages.

 

Articles/Blogs

Videos

Revision number 4, Monday, February 11, 2008 10:10:45 PM by
This is not the most up to date version of this article. The most recent version can be found here.

Comments

This was an interesting article that can help making webapplications easier.

Related Articles

Javascript to display time on Web page

JavaScript sample to continuously display the current time on the web page. Continuously means that the textbox value will be updated with the current time every second. script type="text/javascript"> function ShowTime() { var dt = new Date();

Shortcuts

Table of Contents

Top Wiki Contributors

(last 30 days)

  1. mbanavige (5)
  2. SGWellens (4)
  3. maartenba (2)
  4. rami_nassar (2)
  5. stiansol (2)
  6. MisterFantastic (2)
  7. satish1.v (1)
  8. raklos (1)
  9. mosessaur (1)
  10. Jos Branders (1)

Advertise Here

Microsoft Communities
Page view counter