T
Tommy Jakobsen
Hi.
Is there a problem when trying to use Javascript on a nested masterpage?
On my masterpage, i've got this in the <head>:
<asp:ContentPlaceHolder ID="HeadContent" runat="server" />
And on the nested masterpage:
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
<asp:ContentPlaceHolder ID="NestedHeadContent" runat="server" />
</asp:Content>
And on my content page page:
<asp:Content ID="Content1" ContentPlaceHolderID="NestedHeadContent"
runat="server">
... .js includes goes here ...
<script type="text/javascript">
$(function()
{
$('.startDate-pick').datePicker({startDate:'01/01/1996'});
});
</script">
</asp:Content>
And in the body of the nested page, i've got this input field with the class
used above:
<input id="startDate" name="startDate" type="text" size="7"
class="startDate-pick" />
This works on content pages within the masterpage, but not on content pages
within the nested masterpage. Why is that, and what can I do about it?
Thanks in advance.
Tommy
Is there a problem when trying to use Javascript on a nested masterpage?
On my masterpage, i've got this in the <head>:
<asp:ContentPlaceHolder ID="HeadContent" runat="server" />
And on the nested masterpage:
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
<asp:ContentPlaceHolder ID="NestedHeadContent" runat="server" />
</asp:Content>
And on my content page page:
<asp:Content ID="Content1" ContentPlaceHolderID="NestedHeadContent"
runat="server">
... .js includes goes here ...
<script type="text/javascript">
$(function()
{
$('.startDate-pick').datePicker({startDate:'01/01/1996'});
});
</script">
</asp:Content>
And in the body of the nested page, i've got this input field with the class
used above:
<input id="startDate" name="startDate" type="text" size="7"
class="startDate-pick" />
This works on content pages within the masterpage, but not on content pages
within the nested masterpage. Why is that, and what can I do about it?
Thanks in advance.
Tommy