开发者

jQuery, Anchor, ScrollTo, highlight

开发者 https://www.devze.com 2022-12-21 07:41 出处:网络
I have a large threaded comment list. When a person replies the author gets an email notification. I\'d like the email to have a link to the reply something like: http://site.com/feedback/#reply-22

I have a large threaded comment list. When a person replies the author gets an email notification.

I'd like the email to have a link to the reply something like: http://site.com/feedback/#reply-22

the page would have something like wow nice comment

With jQuery how can I detect the anchor, slowly scroll to the location on page load, and then once it's scrolled to the locati开发者_C百科on highlight the DIV, not highlighting until the scroll is completed?

Thanks


I found this, which might be useful for you. It's a jQuery plugin that allows you to slowly scroll to locations based on just about anything you need.

Here is the link to the project download page.

Use the onAfter:function() {} ability to highlight the comment once the scroll is completed.


This plugin is simple (thanks to its use of .animate and .effect) and works well: jSlideto.

0

精彩评论

暂无评论...
验证码 换一张
取 消