Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php spicepress_before_testimonial_section_trigger(); ?>
- <!-- Testimonial Section -->
- <?php
- $testimonial_options = get_theme_mod('spicepress_testimonial_content');
- if(empty($testimonial_options))
- {
- if( get_theme_mod('home_testimonial_title') != '' || get_theme_mod('home_testimonial_designation') != '' || get_theme_mod('home_testimonial_thumb') != '' || get_theme_mod('home_testimonial_desc') != ''){
- $home_testimonial_title = get_theme_mod('home_testimonial_title');
- $home_testimonial_desc = get_theme_mod('home_testimonial_desc');
- $designation = get_theme_mod('designation');
- $home_testimonial_thumb = get_theme_mod('home_testimonial_thumb');
- $testimonial_options = json_encode( array(
- array(
- 'title' => !empty($home_testimonial_title)? $home_testimonial_title:'Alice Culan',
- 'text' => !empty($home_testimonial_desc)? $home_testimonial_desc :'Sed ut Perspiciatis Unde Omnis Iste Sed ut perspiciatis unde omnis iste natu error sit voluptatem accu tium neque fermentum veposu miten a tempor nise. Duis autem vel eum iriure dolor in hendrerit in vulputate velit consequat reprehender in voluptate velit esse cillum duis dolor fugiat nulla pariatur.',
- 'designation' => !empty($designation)? $designation : 'UI Developer',
- 'link' => '#',
- 'image_url' => !empty($home_testimonial_thumb)? $home_testimonial_thumb : get_template_directory_uri().'/images/item7.jpg',
- 'open_new_tab' => 'no',
- 'id' => 'customizer_repeater_56d7ea7f40b51',
- ),
- ) );
- }
- }
- $testimonial_section_enable = get_theme_mod('testimonial_section_enable','on');
- if($testimonial_section_enable !='off')
- {
- $testimonial_animation = get_theme_mod('testimonial_animation', '');
- $testimonial_animation_speed = get_theme_mod('testimonial_animation_speed', 3000);
- $testimonialsettings=array('animation'=>$testimonial_animation,'animationSpeed'=>$testimonial_animation_speed);
- wp_register_script('spicepress-testimonial',get_template_directory_uri().'/js/front-page/testimonial.js',array('jquery'));
- wp_localize_script('spicepress-testimonial','testimonial_settings',$testimonialsettings);
- wp_enqueue_script('spicepress-testimonial');
- $testimonial_callout_background = get_theme_mod('testimonial_callout_background','');
- if($testimonial_callout_background != '') { ?>
- <section id="testimonial" class="testimonial-section" style="background-image:url('<?php echo esc_url($testimonial_callout_background);?>'); background-repeat: no-repeat; background-position: top left;">
- <?php } else { ?>
- <section id="testimonial" class="testimonial-section">
- <?php }
- $testimonial_overlay_section_color = get_theme_mod('testimonial_overlay_section_color','rgba(0,0,0,0.85)');
- $testimonial_image_overlay = get_theme_mod('testimonial_image_overlay',true);
- ?>
- <div class="overlay"<?php if($testimonial_image_overlay != false) { ?>style="background-color:<?php echo $testimonial_overlay_section_color; } ?>">
- <div class="container">
- <?php
- $home_testimonial_section_title = get_theme_mod('home_testimonial_section_title',__('What our clients say','spicepress'));
- $home_testimonial_section_discription = get_theme_mod('home_testimonial_section_discription','Sea summo mazim ex, ea errem eleifend definitionem vim. Ut nec hinc dolor possim mei ludus efficiendi ei sea summo mazim ex.');
- ?>
- <?php if( $home_testimonial_section_title != '' || $home_testimonial_section_discription != '') { ?>
- <!-- Section Title -->
- <div class="row">
- <div class="col-md-12">
- <div class="section-header">
- <h1 class="white wow fadeInUp animated" data-wow-delay="0ms" data-wow-duration="500ms">
- <?php echo esc_attr($home_testimonial_section_title); ?>
- </h1>
- <div class="widget-separator"><span></span></div>
- <p class="white wow fadeInDown animated">
- <?php echo esc_attr($home_testimonial_section_discription); ?>
- </p>
- </div>
- </div>
- </div>
- <?php }?>
- <!-- /Section Title -->
- <!-- Testimonial -->
- <div class="row">
- <div id="testimonial-carousel" class="owl-carousel owl-theme col-md-12">
- <?php
- $testimonial_options = json_decode($testimonial_options);
- if( $testimonial_options!='' )
- {
- $allowed_html = array(
- 'br' => array(),
- 'em' => array(),
- 'strong' => array(),
- 'b' => array(),
- 'i' => array(),
- );
- foreach($testimonial_options as $testimonial_iteam){
- $title = ! empty( $testimonial_iteam->title ) ? apply_filters( 'spicepress_translate_single_string', $testimonial_iteam->title, 'Testimonial section' ) : '';
- $test_desc = ! empty( $testimonial_iteam->text ) ? apply_filters( 'spicepress_translate_single_string', $testimonial_iteam->text, 'Testimonial section' ) : '';
- $test_link = ! empty( $testimonial_iteam->link ) ? apply_filters( 'spicepress_translate_single_string', $testimonial_iteam->link, 'Testimonial section' ) : '';
- $open_new_tab = $testimonial_iteam->open_new_tab;
- $designation = ! empty( $testimonial_iteam->designation ) ? apply_filters( 'spicepress_translate_single_string', $testimonial_iteam->designation, 'Testimonial section' ) : '';
- $testimonial_image = ! empty( $testimonial_iteam->image_url ) ? apply_filters( 'spicepress_translate_single_string', $testimonial_iteam->image_url, 'Testimonial section' ) : '';
- ?>
- <div class="item">
- <div class="media testmonial-area">
- <?php $default_arg =array('class' => "img-circle"); ?>
- <div class="author-box">
- <a href="<?php echo $test_link; ?>" <?php if($open_new_tab == 'yes'){ echo 'target="_blank"';}?>>
- <img alt="img" class="img-responsive img-circle" src="<?php echo $testimonial_image; ?>" draggable="false">
- </a>
- </div>
- <div class="media-body">
- <div class="description-box">
- <div class="author-description">
- <p><?php echo wp_kses( html_entity_decode( $test_desc ), $allowed_html ); ?></p>
- </div>
- </div>
- <h4 class="name"> <a href="<?php echo $test_link; ?>" <?php if($open_new_tab == 'yes'){ echo 'target="_blank"';}?>><?php echo $title; ?> </a> -<span class="designation"><?php echo $designation; ?></span></h4>
- </div>
- </div>
- </div>
- <?php } } else
- {
- $image = array('item7','item8','item9');
- $name = array('Alice Culan','Bella Swan','Jenifer Doe');
- $desc =array(__('UI Developer','spicepress'), __('Manager','spicepress'), __(
- 'Designer','spicepress'));
- for($i=0; $i<=2; $i++) { ?>
- <div class="item">
- <div class="media testmonial-area">
- <div class="author-box">
- <img src="<?php echo get_template_directory_uri(); ?>/images/<?php echo $image[$i]; ?>.jpg" class="img-circle" alt="img">
- </div>
- <div class="media-body">
- <div class="description-box">
- <div class="author-description">
- <p><?php echo 'Sed ut Perspiciatis Unde Omnis Iste Sed ut perspiciatis unde omnis iste natu error sit voluptatem accu tium neque fermentum veposu miten a tempor nise. Duis autem vel eum iriure dolor in hendrerit in vulputate velit consequat reprehender in voluptate velit esse cillum duis dolor fugiat nulla pariatur.'; ?>
- </p>
- </div>
- </div>
- <h4 class="name"><?php echo $name[$i]; ?> -<span class="designation"><?php echo $desc[$i]; ?></span></h4>
- </div>
- </div>
- </div>
- <?php } } ?>
- </div>
- </div>
- <!-- /Testimonial -->
- </div>
- </div>
- </section>
- <!-- /Testimonial Section -->
- <div class="clearfix"></div>
- <?php } ?>
- <?php spicepress_after_testimonial_section_trigger(); ?>
Add Comment
Please, Sign In to add comment