[thelist] Javascript: Horizontal scroll with ease effect?

Christian Heilmann codepo8 at gmail.com
Sun Jan 14 18:04:02 CST 2007


> Hi.
> I'm trying to do something with javascript and cannot achieve it.
> I'm designing a site wich navigation is not vertical but horizontal. So,
> what I would like to achieve with javascript is:
>
> - I click on the item X on the menu
> - The scroll is done with X amount of speed that I'm able to specify
> - Before "arriving" to the link (so, another section of the site) the speed
> decreases.
>
> Just that.
> I tried to write it, but failed. Tried to look in Google for something like
> that and found nothing. Maybe I get stucked with something simple...

The YUI library has a component for that and exactly what you need as a demo:
http://developer.yahoo.com/yui/examples/animation/scroll_horiz.html
http://developer.yahoo.com/yui/animation/

-- 
Chris Heilmann
Book: http://www.beginningjavascript.com
Blog: http://www.wait-till-i.com
Writing: http://icant.co.uk/



More information about the thelist mailing list