See Also: ContentPlaceHolder Members
A System.Web.UI.WebControls.ContentPlaceHolder control defines a relative region for content in a master page, and renders all text, markup, and server controls from a related System.Web.UI.WebControls.Content control found in a content page.
A System.Web.UI.WebControls.Content control is associated with a System.Web.UI.WebControls.ContentPlaceHolder using its Content.ContentPlaceHolderID property. Set the Content.ContentPlaceHolderID property to the value of the System.Web.UI.Control.ID property of the related System.Web.UI.WebControls.ContentPlaceHolder control in a master page. More than one System.Web.UI.WebControls.ContentPlaceHolder can be declared in a master page.
Within a content page, only one System.Web.UI.WebControls.Content control can supply the content for a System.Web.UI.WebControls.ContentPlaceHolder in the master page. However, in each content page that uses a master page, you can have separate System.Web.UI.WebControls.Content controls associated with the System.Web.UI.WebControls.ContentPlaceHolder. For example, you can define the System.Web.UI.WebControls.ContentPlaceHolder for the page title in a master page. For each content page that uses the master page, you can add a System.Web.UI.WebControls.Content control that supplies the text and markup for the page title.
For XHTML compliance, an empty title element is created if a title has not been defined or cannot be found.
You can specify default content placed within the System.Web.UI.WebControls.ContentPlaceHolder control tags, but this content is replaced by any content in an associated content page.
For more information about master pages and content pages, see ASP.NET Master Pages.
Example
<asp: ContentPlaceHolder EnableViewState="True|False" ID="string" OnDataBinding="DataBinding event handler" OnDisposed="Disposed event handler" OnInit="Init event handler" OnLoad="Load event handler" OnPreRender="PreRender event handler" OnUnload="Unload event handler" runat="server" Visible="