如何使用asp.net在特定子页面中显示母版页内容 [英] How to display master page content in particular child page using asp.net

查看:82
本文介绍了如何使用asp.net在特定子页面中显示母版页内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





如何仅在特定子页面中显示页面内容

Hi,

How to diaply master page content in only particular child page

推荐答案

方式:在创建子页面时,您可以指定它是否应包含在母版页中。



另一种方式是:在母版页 cs 文件检查页面名称并隐藏母版页内容..
one way: while creating child page you assign whether it should include to the master page or not.

the other way is: In master page cs file check the page name and hide the master page content..


您可以在所需的子页面中指定母版页详细信息。这里 portpolio.aspx 是子网页表单。

You can specify master page details in the required child page. Here portpolio.aspx is child web form.
<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Master.Master" CodeBehind="portfolio.aspx.cs" Inherits="XXXX.portfolio" %>


这篇关于如何使用asp.net在特定子页面中显示母版页内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆