PDA

View Full Version : Scrolling HTML Bookmarks script



seb@tilesofstow.co.uk
06-28-2016, 10:04 PM
DD Demo: http://dynamicdrive.com/dynamicindex5/bookmarkscroll.htm

Hi,

Tried out this script and it works very well.

However, does anyone know how to set an offset to the bookmark? Because my menu stays at the top of the page - even when scrolling, the bookmark is hidden by the menu. What I want is the page to stop scrolling a set number of pixels above (or below) the bookmark.

Thanks for any help

Cheers,

Seb

Beverleyh
06-29-2016, 05:58 AM
We can't diagnose something we can't see. Saying that, try looking into the offsetTop property in conjunction with sticky headers.

If you need more help, please provide a basic/reduced test page that demonstrates the problem, and somebody can take a look.

You can use a free service such as JSBin, CodePen or JSFiddle.

seb@tilesofstow.co.uk
06-29-2016, 08:18 AM
Hi,

Thanks for the quick reply. Here's the page I'm working on: http://www.artwebs.co.uk/colintro.asp

I've tried the offsetTop property, and changed it to -10 - but it doesn't work. Click the options for "collections" on the page to see a demo of what I mean.

Thanks for your help!

Seb

Beverleyh
06-29-2016, 12:54 PM
So this is a Dynamic Drive script?

I've moved it to the appropriate forum so that folks can offer assistance knowing what to work with.

seb@tilesofstow.co.uk
06-29-2016, 03:01 PM
Thanks Beverleyh,

This is my first time on this forum - didn't realise I'd put the question in the wrong category!

Cheers,

Seb