Created
February 27, 2023 14:37
-
-
Save crawford252/4b34bbcc05b78d79b0e30ddc045f9b84 to your computer and use it in GitHub Desktop.
Owl Carousel Pro - Custom Popup Preloader
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function dp_ocp_custom_loader() { | |
ob_start(); | |
?> | |
<div class="dp-ocp-loader"><div class="my_custom_loader"></div></div> | |
<style> | |
.dp-ocp-loader { | |
position: absolute; | |
top: 50%; | |
left: 50%; | |
margin-top: -30px; | |
margin-left: -30px; | |
} | |
.my_custom_loader { | |
border: 8px solid #f3f3f3; | |
border-top: 8px solid #3498db; | |
border-radius: 50%; | |
width: 60px; | |
height: 60px; | |
animation: spin 2s linear infinite; | |
margin: 0 auto; | |
} | |
@keyframes spin { | |
0% { transform: rotate(0deg); } | |
100% { transform: rotate(360deg); } | |
} | |
</style> | |
<?php | |
return ob_get_clean(); | |
} | |
add_filter('dp_ocp_custom_loader', 'dp_ocp_custom_loader'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment