How to block scrolling when menu open?

Hi,

I would like to block scrolling on the page when my left menu is open. Is that possible to make? If yes, could you let me know how to make it.

Thank you in advance for your help,
Aurélien


Here is my site Read-Only: https://preview.webflow.com/preview/dcproject?utm_medium=preview_link&utm_source=dashboard&utm_content=dcproject&preview=264a791c40b4a0aed19800d078ce1bfc&workflow=preview

Is someone can have a look for us, please?

This has been discussed here before. Here a couple of examples, but you’ll find other threads if you search some more.

1 Like

Hi @spirelli,

I managed to stop my body page scrolling while my side menu is open thank to your script.

After implementing the piece of javascript that I find in the related topic, none of my CTA in my side menu is working. I checked under the designer panel and all CTA are properly link to the page I want.

Any idea on how to resolve this issue, please? It’s quite urgent as users can’t use my website…

Many thanks for your time,
Aurélien

Preview URL: Webflow - Drover Club

Live URL: https://www.droverclub.com/

As it’s blocking my users experience, I decide to keep the code only on the contact page if you need to have a look.

Please find attached script added.

Many thanks for your time given,
Aurélien

Hi,

Anyone to help, please?

Could also take a look at this implementation that I’ve just come across.

1 Like

Thank you Spirelli! Problem resolved :smiley:

HI @Drover I didn’t look on your site what you have done but next time you can try add and remove fixed element interaction with attention to z-index What I mean that nav should have highest z-index this mean higher than fixed element preventing scroll. It is very easy to setup without need of extra library.

m2c

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.