anchor links on the same page do not work
-
Hi Armin
I have the same problem as I saw others had discussed in the forum; anchor links do not work on my page.
https://neu.casanova-mechanik.ch/
The page is a one-pager.
The idea is that by clicking the blue word > Fotogalerie, you get directed down to the first image of the picture gallery which has the id firstpic .top of the page with link:
how it should look when clicking the link:
I tried to set as a link only the hashtag (#firstpic) or the whole url (https://neu.casanova-mechanik.ch/home/#firstpic). In both cases the link won't be opened by the browser when clicking the word > Fotogalerie.
The url https://neu.casanova-mechanik.ch/home/#firstpic also doesn't work when I directly use it in the browser, the page doesn't jump to the anchor but just shows up from the first row.The problem happens on Chrome and Safari and on my iPhone.
I also tried Turn Off All Custom Code and I disabled all plugins and updated LayTheme, as you suggested for similar problems in the forum. And I activated Never change scrolling position when navigating in Lay Options as it helped another user. Unfortunately, none of this did work so far.
Until now I only properly costumed on the desktop version, the mobile is still a bit of a mess. But the anchor link doesn't work on either of them.
Do you have any idea what else could be helpful?
I used the anchor links a lot on another website and everything worked and still works perfectly there, so it surprises me not being able to deal with it this time.
Thanks a lot for your help,
best,
Florine -
can you disable the overlay feature in lay options
and try again if it works?
i see in the code the homepage is inside an overlay and exists as a normal pageso it exists in the code twice at the moment
maybe there is an issue with that, i will try and recreate this issue and fix the anchorscroll for that -
ok yea, it happens because of that.
will be fixed with the next update -
no i meant please disable the overlay option, not the cover option.
or don't have the homepage set as an overlay.
but yea with the next update it will be fixed -
Hi Armin
I'm really sorry to come up again with this but the link still does not work. If i click '> unsere Fotogalerie', just nothing happens. I updated to the latest Version and I do not have the homepage set as an overlay anymore.
Thanks for your help! -
Having the same issue with the second (contact) menu in this onepager while the first one called (works) does the job correctly.
One click only jumps a bit down, so one would have to click multiple times to get to the correct position.
Things I tried unsuccessfully:
- searching the forum
- updating Lay Theme
- disabling Never change scrolling position when navigating
- disabling overlay option for pages
Many thanks!
-
oh and I transferred my website to the main site, so it is now on https://casanova-mechanik.ch/ and the permalink I yould like to open is https://casanova-mechanik.ch/#firstpic
-
hey if you update lay theme now it should work i think with version 7.2.7
-
did you disable your caching plugin or like refresh it?
if it still doesnt work:
can you send your website address, /wp-admin/ username and password and a link to this topic to info@laytheme.com?
-
can you put you not use the id on the sticky element but on an element below the sticky element
probably its some kind of exception with sticky elements
-
@arminunruh Did work like this – thanks!
Before you post:
- When using a WordPress Cache plugin, disable it or clear your cache.
- Update Lay Theme and all Lay Theme Addons
- Disable all Plugins
- Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"
This often solves issues you might run into
When you post:
- Post a link to where the problem is
- Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
- If the problem is difficult to explain, post screenshots / link to a video to explain it