문제

This is my example site.

https://www.practo.com/bangalore/dermatologist-cosmetologist/anekal

In this when the "Book Appointment" button is clicked. A dropdown block appears and the page scrolls itself to top to make the block completely visible to the user.

I want to do the same in a website, so I need to know how its done. Can someone please help me with this.

Thanks in Advance...............

도움이 되었습니까?

해결책

Add an anchor to the corresponding block, call the anchor when clicking the button. You could use a javascript scrollTo plugin for the animated effect. (as already mentioned.)

다른 팁

There is a plugin for jQuery that covers that kind of functionality: http://demos.flesler.com/jquery/scrollTo/

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top