Apparently it is not possible to use bookmarks (id="") in a menu to get to a certain point on a page (via #mark)

Or am I overlooking something?

Most helpful answers

If full URLs are problematic, e.g. when you have two environments of the same site, you can use the path without the domain. Just use the 'system' path, for example:

node/123#your-id

Comments

indigoxela's picture

Hi Egmund,

the trick is to use the full url, like:

http://your-domain.tld/your-page-path#your-id
Olafski's picture

If full URLs are problematic, e.g. when you have two environments of the same site, you can use the path without the domain. Just use the 'system' path, for example:

node/123#your-id

Yes, that is more 'neat' - to my liking - and it works

My mistake was using the title/name of the page instead of node number.

This is because of the sticky header menu.

What you will need is some way of offsetting it. Here is one example:

https://stackoverflow.com/a/13184714/24246072

Give your anchor a class:

<a class="anchor" id="top"></a>

You can then position the anchor an offset higher or lower than where it actually appears on the page, by making it a block element and relatively positioning it. -250px will position the anchor up 250px

a.anchor {
    display: block;
    position: relative;
    top: -250px;
    visibility: hidden;
}  

 

Thank you - that works - the first one.