Answer the question
In order to leave comments, you need to log in
Why does the scroll disappear after opening and closing the modal several times?
I am developing the site xn--d1ami.xn--j1amh . I press - "call you back" or - "write to us" then I click outside the modal, then I do this several times (opening the modal, clicking on the screen outside the modal) and the page scroll disappears. How to fix it ? In which direction to move?
Answer the question
In order to leave comments, you need to log in
See what happens with . First, the tag is clean. After opening the modal for the first time, it receives a . After clicking past the modal, the class is removed. If you do the same a second time, then it remains. Well, in the CSS for this class , that's why there is no scroll.
This is what is visible in debugging. Bootstrap I don't know. <body>
class='modal-open'
class='modal-open'
overflow: hidden
After closing the modal, the modal-open class is not removed from the body.
jQuery v1.12.4 Try a newer version. Errors are coming from the bootstrap library itself.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question