Hm.. second time I hear that, should I improve the documentation of jQuery.ScrollTo? So you need to scroll the page only once, each time it loads?
Try this (I'll use ScrollTo but you can certainly avoid it if you want) $(function(){ var target = location.hash && $(location.hash)[0]; if( target ) $.scrollTo( target, { speed:1000,.....} ); }); Ariel Flesler On 3 dic, 14:49, Maccer <[EMAIL PROTECTED]> wrote: > Hi! > > Maybe I should have mentioned that I tried the ScrollTo plugin before I > started this topic, but I couldn't get it to work the way I needed. Some > example code that shows how to make any of these plugins use the anchor from > the current page URL would be very helpful. As I mentioned I can't simply > add click behaviours to the links themselves since the page is reloaded > after each click. > > /Aram > > > > > > Andy Matthews-4 wrote: > > > There are several plugins for this behavior: > > >http://www.freewebs.com/flesler/jQuery.LocalScroll/ > > >http://www.freewebs.com/flesler/jQuery.ScrollTo/ > > > -----Original Message----- > > From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On > > Behalf Of Maccer > > Sent: Monday, December 03, 2007 8:30 AM > > To: jquery-en@googlegroups.com > > Subject: [jQuery] Smoothly scroll to the anchor given in the URL > > > Hi! > > > I have a page with a imagemap with link areas. The hrefs look like this: > > > href="<?php echo $_SERVER['PHP_SELF'] ?>?city=NameOfCity#memberlist" > > > When one of those links are clicked, I would like the page to smoothly > > scroll down to the anchor #memberlist. However, the page is reloaded and > > processed by PHP when a link is clicked, so it seems that it is not > > possible > > to use, say, a jquery plugin that scrolls to anchors on the same page - at > > least not without modifications. > > > I think that one solution would be to read the anchor name from the page > > URL > > and then somehow smoothly scroll down to that anchor. But I can't get it > > to > > work. Can anyone suggest how I can accomplish this? > > -- > > View this message in context: > >http://www.nabble.com/Smoothly-scroll-to-the-anchor-given-in-the-URL-... > > 99s27240.html#a14131044 > > Sent from the jQuery General Discussion mailing list archive at > > Nabble.com. > > -- > View this message in > context:http://www.nabble.com/Smoothly-scroll-to-the-anchor-given-in-the-URL-... > Sent from the jQuery General Discussion mailing list archive at Nabble.com.- > Ocultar texto de la cita - > > - Mostrar texto de la cita -