I'm starting to use quite a bit of jquery and java scripts on my page, and the header of each page is starting to become untidy.
Like css, is there any way to hold the script information on another page, so it can be generically used through the site?
for example i have,
is there any way to hold the function in another page, and reference it?
Like css, is there any way to hold the script information on another page, so it can be generically used through the site?
for example i have,
Code:
<link rel="stylesheet" href="../css/style.css">
<link rel="stylesheet" href="../css/reset.css">
<script type="text/javascript" src="../js/jquery.js"></script>
<script type="text/javascript" >
$(function()
{
$(".delete").click(function(){
var element = $(this);
var I = element.attr("id");
$('.alert').fadeOut('slow', function() {$(this).remove();});
return false;
});
});
</script>
is there any way to hold the function in another page, and reference it?