I have a bootstrap modal window that normally has the scroll for the body.
How can I make the modal scroll appear for the entire modal window? since when the body grows, when adding components, I can't see the top of the modal
I have a bootstrap modal window that normally has the scroll for the body.
How can I make the modal scroll appear for the entire modal window? since when the body grows, when adding components, I can't see the top of the modal
With
css
we can do it with a simple codestyle="overflow-y: scroll;"
in thediv
main of themodal
, we simply add it and it already creates ascroll
single formodal
which you indicate it.NOTE:
Run it on the small demo screen and open the 2nd
modal
with the first button of theplus
, you will see that it has ascroll
for it.I suppose that what you want to do is to apply even
scroll
when.modal-body
it exceeds a certain height the is displayedscroll
, if that is what you want to do, you just have to add this rule in your CSS:This applies a fixed height to the body of the modal so you can see the
.modal-header
and.modal-footer
. I leave you the example.What has worked for me is
style="overflow-y:auto"
to place a div.modal
(within which the entire dialog is) so that the entire dialog is scrolled: