Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to view master page in browser

just learning master page, i have a master page which include a content. but how to view the page .master in browser? what it the url?

<%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <asp:ContentPlaceHolder id="head" runat="server">
    </asp:ContentPlaceHolder>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">

        </asp:ContentPlaceHolder>
    </div>
    </form>
</body>
</html>
like image 992
hkguile Avatar asked Oct 24 '12 09:10

hkguile


1 Answers

No, you can not view master page (.master) in browser - because it is not an actual page but a Control which encloses the content of .aspx pages.

When users request the content pages(.aspx), they merge with the master page (.master) to produce output that combines the layout of the master page with the content from the content page.

A single master page defines the look and feel and standard behavior that you want for all of the pages (or a group of pages) in your application.

enter image description here

For more information please read - ASP.NET Master Pages

like image 60
Parag Meshram Avatar answered Oct 13 '22 01:10

Parag Meshram