D
David C
Can I have javascript in both the Master Page and inside the Content page?
I want to keep shared js inside the Master and have additional js inside the
content page. I tried using the ContentPlaceHolderID="head" in the content
page but then the Master Page "head" was ignored. My Master Page "head"
example is below. Thanks.
David
<asp:ContentPlaceHolder ID="head" runat="server">
<script language="javascript" type="text/javascript">
function getScrollBottom(p_oElem) {
return p_oElem.scrollHeight - p_oElem.scrollTop -
p_oElem.clientHeight;
}
function opentasks(stid) {
var surl = 'Tasks.aspx?tid=' + stid;
//give new window a name so we know where we came from when
closing task screen
window.open(surl, "viahome",
"height=475,width=800,status=yes,toolbar=no,menubar=no,location=no");
}
function openemail(spid) {
var surl = 'Tasks.aspx?pid=' + spid;
//give new window a name so we know where we came from when
closing task screen
window.open(surl, "viahome",
"height=475,width=760,status=yes,toolbar=no,menubar=no,location=no");
}
</script>
</asp:ContentPlaceHolder>
I want to keep shared js inside the Master and have additional js inside the
content page. I tried using the ContentPlaceHolderID="head" in the content
page but then the Master Page "head" was ignored. My Master Page "head"
example is below. Thanks.
David
<asp:ContentPlaceHolder ID="head" runat="server">
<script language="javascript" type="text/javascript">
function getScrollBottom(p_oElem) {
return p_oElem.scrollHeight - p_oElem.scrollTop -
p_oElem.clientHeight;
}
function opentasks(stid) {
var surl = 'Tasks.aspx?tid=' + stid;
//give new window a name so we know where we came from when
closing task screen
window.open(surl, "viahome",
"height=475,width=800,status=yes,toolbar=no,menubar=no,location=no");
}
function openemail(spid) {
var surl = 'Tasks.aspx?pid=' + spid;
//give new window a name so we know where we came from when
closing task screen
window.open(surl, "viahome",
"height=475,width=760,status=yes,toolbar=no,menubar=no,location=no");
}
</script>
</asp:ContentPlaceHolder>