Block page
Block page to prevent (mini) DOS.
HTML
<!-- This is the busy overlay, show when Startig quiz... -->
<div class="modal-overlay" id="modalOverlay">
<div class="modal-dialog">
<div class="loader"></div>
<p>Please wait... </p>
</div>
</div>
CSS
.modal-overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.6);
display: flex;
justify-content: center;
align-items: center;
z-index: 1000;
display: none;
}
.modal-dialog {
position: fixed;
top: 35%;
left: 40%;
background: #fff;
border-radius: 5px;
padding: 20px;
text-align: center;
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
}
.loader {
border: 4px solid #f3f3f3;
border-top: 4px solid #3498db;
border-radius: 50%;
width: 40px;
height: 40px;
animation: spin 2s linear infinite;
margin: 0 auto;
margin-bottom: 10px;
}
@keyframes spin {
0% {
transform: rotate(0deg);
}
100% {
transform: rotate(360deg);
}
}
xx