Server IP : 66.29.132.124 / Your IP : 18.118.0.93 Web Server : LiteSpeed System : Linux business141.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : wavevlvu ( 1524) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/wavevlvu/misswavenigeria.com/wp-content/plugins/ombre-features/ |
Upload File : |
<?php $args = array( 'post_type' => 'ombretestimonials', 'posts_per_page' => 99 ); $the_query = new WP_Query( $args ); if (is_rtl()) { $array_rev = array_reverse($the_query->posts); $the_query->posts = $array_rev; } if ( $the_query->have_posts() ) { $random = rand(); ?> <div id="testimonials<?php echo esc_attr($random); ?>" class="owl-carousel testimonials"> <?php while ( $the_query->have_posts() ) : $the_query->the_post(); ?> <?php $ombrequotecontent = get_post_meta( get_the_id(), 'ombrequotecontent', true ); ?> <div class="testimonial"> <div class="testimonial-right <?php if ( ! has_post_thumbnail() ) { ?>withoutimg<?php } ?>"> <div class="testimonial-text"> <?php echo apply_filters('the_content',$ombrequotecontent); ?> <p class="testimonial-cite"><span>―</span> <?php the_title(); ?></p> </div> </div> <?php if ( has_post_thumbnail() ) { ?> <div class="testimonial-left"> <?php $thumb_id = get_post_thumbnail_id(); $thumb_url_array = wp_get_attachment_image_src($thumb_id, 'thumbnail', true); $thumb_url = $thumb_url_array[0]; ?> <img src="<?php echo esc_url($thumb_url); ?>" alt="<?php the_title(); ?>" /> <div class="testimonial-nav"> <div class="testimonial-nav-left"><i class="fa fa-chevron-left"></i></div> <div class="testimonial-nav-right"><i class="fa fa-chevron-right"></i></div> </div> </div> <?php } ?> </div> <?php endwhile; ?> </div> <script type="text/javascript"> jQuery(window).on('load', function () { "use strict"; jQuery(".testimonials").show(); var owl = jQuery("#testimonials<?php echo esc_js($random); ?>").owlCarousel({ items: 1, <?php if (is_rtl()) { echo esc_js("rtl:true,"); } ?> autoplay: <?php echo esc_js($autoplay); ?>, autoplayTimeout: <?php echo esc_js($duration); ?>000, autoplayHoverPause: true, dots: false, autoHeight: <?php echo esc_js($autoheight); ?>, margin: 100, mouseDrag: false, touchDrag: false, smartSpeed: 800, nav: false, loop: true, animateIn: 'fadeIn', animateOut: 'fadeOut' }); jQuery('#testimonials<?php echo esc_js($random); ?>').find('.testimonial-nav-left .fa').click(function() { owl.trigger('prev.owl.carousel'); }); jQuery('#testimonials<?php echo esc_js($random); ?>').find('.testimonial-nav-right .fa').click(function() { owl.trigger('next.owl.carousel'); }); }); </script> <?php } wp_reset_postdata(); ?>