JQuery Rounded Corners on MasterPage
Hey folks,
I'm trying to use JQuery rounded corners to be applied to a div I have. However I can't seem to get the corners rounded. I'm actually applying on the master page so that its inherited on all of the sub-pages as well. I'm not sure if naturally JQuery exists within the project and so me referencing it twice could be an issue, can it be?
I created as separate page to apply the JQuery and it works, however when applied to the MasterPage it doesn't call the function at all. Can someone advise if there is a particular way for using JQuery in the MasterPages please.
I'm using these references.
01.
<script type=
"text/javascript"
src=
"http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"
></script>
02.
03.
<script type=
"text/javascript"
language=
"javascript"
src=
"https://raw.github.com/malsup/corner/master/jquery.corner.js"
></script>
04.
<script language=
"javascript"
type=
"text/javascript"
>
05.
$(document).ready(
function
()
06.
07.
$(
'#articletitle'
).corner();
08.
);
09.
</script>
Hi Jase,
You can use javascript coding in .master file by referencing the needed .js and then calling them in <script> divs. Include the JS files like in the sample. Please check code example bellow:
<
script
type
=
"text/javascript"
src
=
"https://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"
></
script
>
<
script
type
=
"text/javascript"
src
=
"https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.10/jquery-ui.min.js"
></
script
>
<
script
>
your code here
</
script
>