Why isn't this Jquery keypad working when I use a master page?
<p>Click <a href="http://keith-wood.name/keypad.html" rel="nofollow">here</a> for the source of the jquery keypad.</p>

<p>I have used this keypad in my project at a separate form and it works but whenever I use the same thing in another form with a master page it doesn't work. In my master page all off he necessary references are added (same references are also added in the head part of the form just in case!) </p>

<pre><code>&lt;script src="../App_Themes/Default/js/jquery-1.6.1.js" type="text/javascript"&gt;&lt;/script&gt;

&lt;%--&lt;script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"&gt;&lt;/script&gt;--%&gt;

&lt;script src="../App_Themes/Default/js/jquery.keypad.js" type="text/javascript"&gt;    &lt;/script&gt;

&lt;script type="text/javascript"&gt;
$(function () {
$('#txtFTP').keypad();

});
&lt;/script&gt; 
</code></pre>

<p>Even if I delete my masterpage reference of the same form and I replace my content place holders with HTML tags the jquery keyboard works. </p>

<p>Can anyone suggest me why isn't it working?</p>

<p><strong>UPDATE 1</strong></p>

<p>To test more about this problem I have created a new test masterpage. The code: </p>

<pre><code>&lt;%@ Master Language="C#" AutoEventWireup="true" CodeFile="TestMasterPage.master.cs" 

 Inherits="Member_TestMasterPage" %&gt;

&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org

/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;


&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head runat="server"&gt;
 &lt;title&gt;Untitled Page&lt;/title&gt;
 &lt;asp:ContentPlaceHolder id="head" runat="server"&gt;
 &lt;/asp:ContentPlaceHolder&gt;
&lt;/head&gt;
&lt;body&gt;
 &lt;form id="form1" runat="server"&gt;
  &lt;div&gt;
    &lt;asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server"&gt;

    &lt;/asp:ContentPlaceHolder&gt;
  &lt;/div&gt;
 &lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>As you can see that there is no reference in the master page for jquery.</p>

<p>Then I created a new test.aspx page. The code: </p>

<pre><code>&lt;%@ Page Language="C#" MasterPageFile="~/Member/TestMasterPage.master" 

AutoEventWireup="true" CodeFile="2.aspx.cs" Inherits="_2" %&gt;

&lt;asp:Content ContentPlaceHolderID="head" runat="server"&gt;
 &lt;script src="../App_Themes/Default/js/jquery-1.6.1.js" type="text/javascript"&gt; 
 &lt;/script&gt;

 &lt;script src="../App_Themes/Default/js/jquery.keypad.js" type="text/javascript"&gt;
 &lt;/script&gt;

 &lt;script type="text/javascript"&gt;
   $(function () {
$('#txtFTP').keypad();

   });
 &lt;/script&gt;
&lt;/asp:Content&gt;

&lt;asp:Content ContentPlaceHolderID="ContentPlaceHolder1" runat="server"&gt;
 &lt;div&gt;
  &lt;asp:TextBox ID="txtFTP" SkinID="Mini" runat="server" TextMode="Password"   
  ForeColor="Gray" /&gt;
 &lt;/div&gt;
&lt;/form&gt;

&lt;/asp:Content&gt;
</code></pre>

<p>But the jquery keyboard doesn't work. But if I remove the master page reference and change the page accordingly the keyboard works! The code:</p>

<pre><code>&lt;%@ Page Language="C#" AutoEventWireup="true" CodeFile="2.aspx.cs" Inherits="_2" %&gt;

&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org 
/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;

&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head runat="server"&gt;
&lt;title&gt;Untitled Page&lt;/title&gt;

&lt;script src="../App_Themes/Default/js/jquery-1.6.1.js" type="text/javascript"&gt;&lt;/script&gt;

&lt;script src="../App_Themes/Default/js/jquery.keypad.js" type="text/javascript"&gt;  
&lt;/script&gt;

&lt;script type="text/javascript"&gt;
$(function () {
$('#txtFTP').keypad();

});
&lt;/script&gt;

&lt;/head&gt;
&lt;body&gt;
&lt;form id="form1" runat="server"&gt;
&lt;div&gt;
&lt;asp:TextBox ID="txtFTP" SkinID="Mini" runat="server" TextMode="Password"  
ForeColor="Gray" /&gt;
&lt;/div&gt;
&lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p><strong>What am I doing wrong? Why can't I make it work with a master page?</strong></p>
