[jQuery] Creating ScrollTo link with JQuery
Hai,
i try to create a link with JQuery but i get failed. Please help me
and give me the solution for this.
I am newbie. I am not good understand javascript.
!! ~ ~ ~ ~ ~ !!
I want to create link like this :
<a id="name1" href="#" onclick="function();">This will be go to the
name2 with ScrollTo</a>
<h3 id="name2">This is the destionation ScrollTo</h3>
!! ~ ~ ~ ~ ~ !!
I have create this code on <head> :
$(document).ready(function(){
$('#name1').localScroll({ target:'#name2', axis:'xy', queue:true });
};
!! ~ ~ ~ ~ ~ !!
I have load the jquery.js & jquery.scrollTo.js in head like this :
<script src="js/jquery.js" type="text/javascript"></script>
<script src="js/jquery.scrollTo.js" type="text/javascript"></script>
But there is still not working.
What's wrong , i have try the way from Ariel Fleshler on his blog. But
i still get failed.
Any ideas, please ?
Thanks