dcsimg
www.webdeveloper.com
Results 1 to 3 of 3

Thread: [RESOLVED] getting crazy will ScrollTo

  1. #1
    Join Date
    Aug 2004
    Location
    Switzerland
    Posts
    1,101

    resolved [RESOLVED] getting crazy will ScrollTo

    Hi...
    I've been spending my day on this. I'm trying to implement Ariel Flesler plugin ScrollTo (http://flesler.blogspot.ch/2009/05/j...-released.html) in my website. I can't get it to work. I've doubled checked everything, I've tried all sorts of crazy solutions, and no way.
    What I want to do is really simple :
    I want to scroll the window horizontally to 1290px.

    This is my code :
    HTML Code:
    <a title="$.scrollTo( {top:'0px', left:'1290px'}, 800 );" href="#">Auteurs</a>
    I'm of course calling the scrollTo js file and jquery file in the header of the document.

    I've tried scrolling to a specific element using $.scrollTo( '#auteurstarget', 800) and having of course a div called auteurstarget, but didn't work either.

    My website (in construction) is here : http://www.espacescomprises.com

    (I'm trying to scroll to the big ugly red rectangle, when clicking on "auteurs", that is the third piece of paper from the left on the top menu)

    Thanks for all advice, I'm getting desperate here There is probably a tiny something wrong, but I'm totally unable to find it. Oh, and of course, I tried the debugging console, I'm not getting any error or warning.

  2. #2
    Join Date
    Mar 2009
    Posts
    452
    i think it should be like this
    <a title="$.scrollTo( {top:'0px', left:'1290px'}, 800 );" href="javascrpt:void(0)">Auteurs</a>

  3. #3
    Join Date
    Aug 2004
    Location
    Switzerland
    Posts
    1,101
    Tried it, it didn't work
    I also tried another scrollTo script I found, and also the mootools version of scrollTo. Neither works. I'm getting crazy with it, spent almost my whole night on it. I'm sure it's a stupid and tiny think preventing it to work, but I'm totally unable to find it


    Solved it ! I found another thread on a forum, so that did the trick :

    HTML Code:
    <a href="#auteurstarget" onclick="$.scrollTo( '#auteurstarget', 800, {easing:'easeOutCirc'} );">Auteurs</a>
    I also played a little with the jquery easing library. So all is fine now
    Last edited by Ness_du_Frat; 09-29-2012 at 08:02 AM. Reason: solved the problem

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles