I think that happens because you first need to reset the scroll to
(0,0).
The browser also scrolls natively.

I'm planning to add this within $.localScroll.hash, as well as taking
advantage of sync animations, added since 1.3.
But for now... :)

$(document).ready(function(){
   window.scrollTo(0,0);
   $.localScroll.hash({
      axis:'x',
      duration:1500
   });
   $('#container').localScroll({
     axis:'x',
     hash:true,
     duration: 1000
  });
});

--
Ariel Flesler
http://flesler.blogspot.com

On Mar 4, 3:47 pm, clorentzen <carl.lorent...@gmail.com> wrote:
> Sorry, I hit "post" button too quickly there...
>
> You can see an example linking to a test page here:
>
> http://www.cementresources.com/paneltest/hub.html
>
> I've seen the issue in FF3, Safari 3, and in IE 6 and 7.
>
> Not sure what I'm doing incorrectly. Any help appreciated. Thank you!
>
> On Mar 4, 1:43 pm, clorentzen <carl.lorent...@gmail.com> wrote:
>
> > Hi --
>
> > I'm using the LocalScroll plugin, and having trouble getting it to
> > work when passing the anchor through as part of the URL. Instead of
> > scrolling to the appropriate anchor id, the window just moves a few
> > pixels and stops.
>
> > Calling LocalScroll on links within the page works fine, but not when
> > the link is coming from another page or typed directly in the browser
> > address bar.
>
> > My code for initializing LocalScroll is:
>
> > $(document).ready(function(){
> >     $.localScroll.hash({
> >         axis:'x',
> >         duration:1500
> >     });
> >     $('#container').localScroll({
> >         axis:'x',
> >         hash:true,
> >         duration: 1000
> >     });
>
> > });
>
>

Reply via email to