forked from LiveCarta/LiveCartaWP
17
htdocs/wp-content/themes/lawcarta/assets/js/promoImage.js
Normal file
17
htdocs/wp-content/themes/lawcarta/assets/js/promoImage.js
Normal file
@@ -0,0 +1,17 @@
|
||||
$(document).ready(function () {
|
||||
function promoTopNext() {
|
||||
if ($('.promo-backs').length) {
|
||||
setTimeout(function () {
|
||||
var current = $('.promo-bg.current');
|
||||
current.removeClass('current');
|
||||
if (current.next().length) {
|
||||
current.next().addClass('current');
|
||||
} else {
|
||||
current.parent().find('.promo-bg:first-child').addClass('current');
|
||||
}
|
||||
promoTopNext();
|
||||
}, 4500);
|
||||
}
|
||||
};
|
||||
promoTopNext();
|
||||
});
|
||||
@@ -74,6 +74,7 @@ require_once 'inc/walker-nav-menu.php';
|
||||
<?php wp_footer(); ?>
|
||||
<script src="<?= get_theme_file_uri('/assets/js/featuresScroll.js'); ?>"></script>
|
||||
<script src="<?= get_theme_file_uri('/assets/js/faqSearch.js'); ?>"></script>
|
||||
<script src="<?= get_theme_file_uri('/assets/js/promoImage.js'); ?>"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,5 +0,0 @@
|
||||
document.addEventListener("DOMContentLoaded", function(event) {
|
||||
$('.start-search').on('click', function(){
|
||||
$('#search-form').submit();
|
||||
});
|
||||
})
|
||||
Reference in New Issue
Block a user