To disable scrolling on everything except a modal div in Webflow, you can use custom code to manipulate CSS and JavaScript.
```css
body.modal-open {
overflow: hidden;
}
```
```javascript
document.addEventListener('DOMContentLoaded', function() {
const modal = document.querySelector('.your-modal-class');
const openModalButton = document.querySelector('.open-modal-button');
const closeModalButton = document.querySelector('.close-modal-button');
openModalButton.addEventListener('click', function() {
modal.style.display = 'block';
document.body.classList.add('modal-open');
});
closeModalButton.addEventListener('click', function() {
modal.style.display = 'none';
document.body.classList.remove('modal-open');
});
});
```
.your-modal-class, .open-modal-button, and .close-modal-button with the actual class or ID names used in your project.
To prevent scrolling across the page when a modal div is open in Webflow, apply a combination of custom CSS and JavaScript. The CSS disables body overflow, while the JavaScript toggles a class on the body element to activate or deactivate scrolling based on modal visibility. Ensure you use the appropriate class names from your project in both CSS and JS.