-
Making my prev/next links send me to the top of the page
1) Script Title: Virtual Pagination Script v2.1
2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...pagination.htm
3) Describe problem: I'm using Demo3 on the the Virtual Pagination Script and it's working fine but for one thing - the pagination bar on the bottom of the page doesn't send me to the top of the prev/next pages, it sends me to the bottom, so I have to scroll up. I'm looking to find out how to tweak the code so that when I click prev/next or any of the page numbers on the bottom bar, it sends me to the top of the relevant page. Can you help?
-
-
There's a couple of threads in the past that discuss this, for example: http://www.dynamicdrive.com/forums/s...ad.php?t=41898
DD Admin
-
-
Prev/Next links in virtual pagination not sending to top of page
Hi DDADmin,
Thanks for sending me that link. Unfortunately, the recommendations don't seem to be working for me.
What happens is that when I add the code to the function showpage () in the .js file:
var contentArea=document.getElementById(config.divid)
if (contentArea && contentArea.scrollIntoView)
document.getElementById(config.divid).scrollIntoView()
... I actually lose all functionality of the pagination - the page numbers no longer appear and the prev/next links don't work. I'm too new to javascript to diagnose why this is happening - bit of a rookie I'm afraid, so I'm rather dependent on experts like yourself. If there's anything you can do to help me, I'd really appreciate it - perhaps there's another thread on this topic, another technique? Or perhaps I could send you the html of my page - it's very straightforward really...
Any help much appreciated...
Thanks!
mrsanj
-
-
There must be an error in your set up somehow. Try the below modified .js file instead, which adds the necessary code in.
DD Admin
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks