⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 masterpage.master

📁 一个AJAX框架
💻 MASTER
字号:
<%@ Master Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
	<style type="text/css">
		body
		{ 
			font-family:verdana;
			font-size:small;
			margin-top: 0px;
		}
		fieldset
		{
			width: 700px;
			padding:10px 10px;
		}
		legend
		{
			padding:10px 0px 10px 0px;
		}
	</style>
</head>
<body>
	<form id="form1" runat="server">
		<fieldset>
			<legend><b>MagicAjax.NET Examples for ASP.NET 2.0</b> (.NET version <%= System.Environment.Version %>)<br />Please select one of the demo pages:</legend>
			<asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" ShowStartingNode="False" />
			<asp:Menu ID="Menu1" DataSourceID="SiteMapDataSource1" runat="server" StaticSelectedStyle-BorderStyle="Dotted" StaticSelectedStyle-BorderWidth="2px" StaticSelectedStyle-BorderColor="Green" StaticSelectedStyle-Font-Bold="true" />
		</fieldset>
		
		<hr style="border-style:dashed; border-color:black;" />
		
		<asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server" />
		
		<ajax:ajaxpanel ID="AjaxSourcePanel" runat="server">
			<br /><hr style="border-style:dashed; border-color:black;" />
			<asp:LinkButton ID="ShowSource" runat="server" Text="Show Source" OnClick="ShowSource_Click" />
			<pre runat="server" id="SourceSpan" style="background-color:PapayaWhip" />
		</ajax:ajaxpanel>
	</form>
</body>
</html>

<script language="C#" runat="server">
	private void Page_Load(object sender, EventArgs e)
	{
		 AjaxSourcePanel.Visible = !Request.RawUrl.ToLowerInvariant().EndsWith("/default.aspx");
	}
	protected void ShowSource_Click(object sender, EventArgs e)
	{
		//read current aspx source, and put in SourceSpan
		SourceSpan.InnerHtml = HttpUtility.HtmlEncode(System.IO.File.ReadAllText(Request.PhysicalPath).Replace("\t", "  "));
	}
</script>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -