MasterPage in ASP.Net
- MasterPage is a very useful concept of ASP.Net.
- A single master page defines the look and feel and standard behavior for all of the pages in your .Net application.
- Start to Create a MastePage in ASP.Net
- First, Add new masterpage in your web application from add new item tab.
- give the name of masterpage which you want. and then click add button to create new masterpage in your web application.
- After doing this, you will have a below screen.
- which describe the HTML code of MastePage.
- Below screen is design view of MasterPage.
- Design your Masterpage with your ideas.
- After Designing Masterpage we must apply this Masterpage to your web pages.
- For applying MasterPage on your Webpage,
- Open the HTML code view of your webpage.
- Remove all code with tag.
- Remove all HTML coding from Webpage.
- Write down code on HTML side for add ContentPlaceHolder as per the shown in below figure.
- After, doing this Masterpage apply on your web page.
(Visited 1 times, 1 visits today)