问题描述
这是我的母版页设计代码
This is my Master page design code
<%@ Master Language="C#" AutoEventWireup="true" CodeFile="mainMasterPage.master.cs" Inherits="mainMasterPage" %>
<!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>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>Metamorphosis Design Free Css Templates</title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<link href="styles.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" type="text/css" href="calender/calandar.css" />
<script type="text/javascript" src="calender/calandar.js"></script>
<asp:ContentPlaceHolder id="head" runat="server">
</asp:ContentPlaceHolder>
<style type="text/css">
.style3
{
width: 1062px;
margin-left: 0;
}
.style4
{
height: 65px;
}
</style>
</head>
<body>
<form id="frm1" runat="server">
<div class="bg_foot">
<div id="main">
<!-- header begins -->
<div id="header">
<div id="logo"
style="font-family: 'Monotype Corsiva'; font-size: 50px; font-weight: bold; text-transform: capitalize; color: #CCFFFF"
class="style4">
<span lang="en-us"> </span>Optimal service pricing for a cloud cache
</div>
<div id="buttons">
<a href="homepage.aspx" title="" style="color: #0000CC; font-style: normal;">Home</a>
<a href="login_page.aspx" title="" style="color: #0000CC; font-style: normal;">Login</a>
<a href="registrationpage.aspx" title="" style="color: #0000CC; font-style: normal;">Registration</a>
<a href="#" title="" style="font-style: normal; color: #0000CC">About Us</a>
<a href="#" title="" style="color: #0000CC; font-style: normal">Contact Us</a>
</div>
</div>
<!-- header ends -->
<!-- content begins -->
<div id="content" class="style3" >
<div id="center" >
<asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
</asp:ContentPlaceHolder>
</div>
</div>
<!-- content ends --><br />
<!-- footer begins -->
<div id="footer">
<p style="font-weight: bold; color: #003300">Copyright ©2012.2.<a href="#"
style="color: #0000FF; font-weight: bold; text-decoration: underline;">Graft Tech</a></p>
</div>
<!-- footer ends -->
</div>
</div>
</form>
</body>
</html>
这是我的注册页面设计代码
This is my registration page design code
<%@ Page Language="C#" MasterPageFile="~/mainMasterPage.master" AutoEventWireup="true" CodeFile="freeuserreg.aspx.cs" Inherits="freeuserreg" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
<script type="text/javascript">
$(function () {
new JsDatePick({useMode:2,target:"txtdob",dateFormat:"%d-%m-%Y"});
});
</script>
<style type="text/css">
.style5
{
width: 130px;
}
.style7
{
width: 197px;
}
.style8
{
width: 49px;
}
.style9
{
width: 213px;
}
</style>
<style type="text/css">
.style5
{
width: 263px;
}
.style6
{
width: 522px;
}
.style7
{
width: 204px;
}
.style8
{
width: 207px;
}
.style9
{
width: 254px;
}
</style>
<style type="text/css">
.style5
{
width: 168px;
}
.style6
{
width: 487px;
}
.style7
{
width: 191px;
}
.style8
{
width: 196px;
}
.style9
{
width: 240px;
}
.style10
{
width: 149px;
}
.style11
{
width: 191px;
height: 45px;
}
.style12
{
width: 213px;
height: 45px;
}
.style13
{
width: 191px;
height: 48px;
}
.style14
{
width: 213px;
height: 48px;
}
.style15
{
width: 191px;
height: 43px;
}
.style16
{
width: 213px;
height: 43px;
}
.style17
{
width: 191px;
height: 42px;
}
.style18
{
width: 213px;
height: 42px;
}
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<h1 style="font-size: xx-large; color: #CCFF99; font-family: 'Monotype Corsiva';">
FREE USER REGISTRATION</h1><br />
<table><tr>
<td class="style5"></td>
<td class="style6">
<table>
<tr>
<td class="style7">
<asp:Label ID="lbluname" runat="server" Text="User Name"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label>
<br />
<br />
</td>
<td class="style9"> <asp:TextBox ID="txtuname" runat="server"
Height="25px" Width="185px" ></asp:TextBox>
<br />
<asp:LinkButton ID="check" runat="server" Text="Check Availability"
Font-Bold="True" Font-Underline="True" ForeColor="#FFCCCC"></asp:LinkButton>
<asp:Label ID="lblcheck" runat="server" Visible="False" ForeColor="#FFFF66"></asp:Label>
</td>
<td class="style10"></td>
</tr>
<tr>
<td class="style11">
<asp:Label ID="lblpassword" runat="server" Text="Password"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label></td>
<td class="style12"> <asp:TextBox ID="txtpwd" runat="server"
Height="25px" Width="185px" ></asp:TextBox> </td>
</tr>
<tr>
<td class="style13">
<asp:Label ID="lblrepwd" runat="server" Text="Re-Type Password"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label></td>
<td class="style14"> <asp:TextBox ID="txtrepwd" runat="server"
Height="25px" Width="185px" ></asp:TextBox></td>
</tr>
<tr>
<td class="style15">
<asp:Label ID="lblmail" runat="server" Text="Mail Id"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label></td>
<td class="style16"> <asp:TextBox ID="txtmailid" runat="server"
Height="25px" Width="185px" ></asp:TextBox></td>
</tr>
<tr>
<td class="style17">
<asp:Label ID="lbldob" runat="server" Text="DOB"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label></td>
<td class="style18">
<asp:TextBox ID="txtdob" runat="server"
Height="25px" Width="185px" ontextchanged="txtdob_TextChanged" ></asp:TextBox></td>
</tr>
<tr>
<td class="style15">
<asp:Label ID="lblmobileno" runat="server" Text="Mobile No"
Font-Size="Large" ForeColor="#99FF33" Font-Names="Times New Roman"></asp:Label></td>
<td class="style16"> <asp:TextBox ID="txtmobileno" runat="server"
Height="25px" Width="185px" ></asp:TextBox></td>
</tr>
</table>
</td>
<td class="style8"></td>
</tr></table>
</asp:Content>
how to use the jquery in master page and how to call the jquery function in registration page
how to use the jquery in master page and how to call the jquery function in registration page
推荐答案
how to use the jquery in master page and how to call the jquery function in registration page
how to use the jquery in master page and how to call the jquery function in registration page
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
<Scripts>
<asp:ScriptReference Path="/Scripts/jquery-1.3.2.min.js" />
</Scripts>
</asp:ScriptManager>
Then, in the registration page that requires some custom JS files, or a jQuery plugin, you can have
Then, in the registration page that requires some custom JS files, or a jQuery plugin, you can have
<asp:Content ID="bodyContent" ContentPlaceholderID="body">
<asp:ScriptManagerProxy ID="ScriptManagerProxy1" runat="server">
<Scripts>
<asp:ScriptReference Path="/Scripts/jquery.fancybox-1.2.1.pack.js" />
</Scripts>
</asp:ScriptManagerProxy>
The ScriptManager allows you to do things like control where on the page scripts are rendered with LoadScriptsBeforeUI.
The ScriptManager allows you to do things like control where on the page scripts are rendered with LoadScriptsBeforeUI.
这篇关于如何在母版页中添加jQuery的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!