jquery - scrollTo is not a function -
ok, can't see anymore. i'm using the scrollto plugin , have scrollto function in website. worked , doesn't...
this code:
$(document).ready(function() { $('header').delay(300).fadein(750); $('#intro_text').delay(800).fadein(750); $("#jquery_jplayer_1").jplayer({ ready: function () { $(this).jplayer("setmedia", { m4v: "mi4.m4v", ogv: "mi4.ogv", webmv: "mi4.webm", poster: "mi4.png" }); }, swfpath: "js", supplied: "webmv, ogv, m4v", size: { width: "570px", height: "340px", cssclass: "jp-video-360p" } }); }); $(function(todemos) { $('h1').click(function() { $.scrollto('#intro', 800); }); }); $(function(todemos) { $('#contact').click(function() { $.scrollto('footer', 800); }); }); $(function(todemos) { $('#demos').click(function() { $.scrollto('#content', 800); }); }); $(function(todemos) { $('#totop').click(function() { $.scrollto('#intro', 800); }); }); $(function() { $("#playlist li").on("click", function() { $("#videoarea").attr({ "src": $(this).attr("movieurl"), "poster": "", "autoplay": "autoplay" }) }) $("#videoarea").attr({ "src": $("#playlist li").eq(0).attr("movieurl"), "poster": $("#playlist li").eq(0).attr("moviesposter") }) })
i'm beginner @ this, don't think did wrong. there wrong here? can't see it.
hopefully 1 of can! in advance.
if you're using flesler's scrollto plugin, may need modify duration option:
$.scrollto('footer', { duration:800 });
download plugin source here if haven't already. verify correctly linked code. try debugging tool firebug troubleshooting.
note:
to point out mark's answer in comments below stumbles on this, jquery must linked first in order in file before plugins loaded. e.g.:
<script type="text/javascript" src="jquery.min.js"></script> <script type="text/javascript" src="jquery.scrollto.min.js"></script>
Comments
Post a Comment