<?php 

//faq
function faqShortcode($isHome = 0) {
    global $query;

    $args = array('post_type' => 'our-faq'); 

    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    } else {
        $args['paged'] = max(1, get_query_var('paged'));
    }

    if(!empty($isHome) && $isHome == 1){
        $cols = get_theme_mod('faq_section_npp_count', 5);
        $cols++;
        $args['posts_per_page'] = $cols;
    }else{
        $args['posts_per_page'] = (!empty($args['posts_per_page'])) ? $args['posts_per_page'] : -1;
         // $cols = 5;
    }
    $faqPageId = get_theme_mod('faq_section_page_link');
    $query = new WP_Query($args);
    ob_start();
    // print_r($query);
    echo '<div class="faq">';
    if ($query->have_posts()){
        while ($query->have_posts()) : $query->the_post();

            $post = get_post();
            $faqdesignation = get_post_meta($post->ID, 'faqdesignation', false);
            $faqs_designation = !empty($faqdesignation[0]) ? $faqdesignation[0] : '';
            ?>
            <div class="row">
                <div class="col-md-12 faq-content padding0">
                    <div class="panel-heading">
                     <?php if (!empty($faqs_designation)) { ?>
                        <div class="faqs-num"><?php echo ($faqs_designation); ?></div>
                    <?php } ?>
                    
                    <h4 class="panel-title">

                        <?php the_title(); ?>

                    </h4>
                </div>
                <div class="faq-description">
                    <i aria-hidden="true">
                        <b class="cta-animation-components">
                            <b class="cta-animation-components__rect cta-animation-components__rect--1"></b>
                            <b class="cta-animation-components__rect cta-animation-components__rect--2"></b>
                            <b class="cta-animation-components__rect cta-animation-components__rect--3"></b>
                        </b>
                    </i>             

                    <p class="desc-faq"><?php
                    if(!empty($isHome) && $isHome==1){
                        if (has_excerpt()) {
                            echo get_the_excerpt();
                        } else {
                           echo get_the_content();
                       }
                       
                   }else{
                    echo get_the_content();
                }?>
            </p> 
        </div> 
    </div>
</div>
<?php
endwhile;
}else{
    for($i=0; $i<$cols; $i++){
        ?>
        <div class="row">
            <div class="col-md-12 faq-content padding0">
                <div class="panel-heading">
                    <h4 class="panel-title">
                        <a role="button">
                            <i class="icon fa fa-globe"></i>
                            What are the most surreal places to visit?
                        </a>
                    </h4>
                </div>
                <div class="faq-description">

                  <i aria-hidden="true">
                    <b class="cta-animation-components">
                        <b class="cta-animation-components__rect cta-animation-components__rect--1"></b>
                        <b class="cta-animation-components__rect cta-animation-components__rect--2"></b>
                        <b class="cta-animation-components__rect cta-animation-components__rect--3"></b>
                    </b>
                </i> 

                <p><?php
                if(!empty($isHome) && $isHome==1){
                    ?>
                    Lorem Ipsum is simply dummy text of the printing and tysetting industry. Lorem Ipsum has been the indstry's standard dumy text ever since the 1500s, when an unwn printer took a galley of type and scrambled it to make a type specimen book. remaining essentially uncnged. It was popularised in the with theLorem.
                    <br>
                    <?php
                    
                }else{
                    ?>
                    Lorem Ipsum is simply dummy text of the printing and tysetting industry. Lorem Ipsum has been the indstry's standard dumy text ever since the 1500s, when an unwn printer took a galley of type and scrambled it to make a type specimen book. remaining essentially uncnged. It was popularised in the with theLorem.
                    <?php
                }?>
            </p>
        </div>  
    </div>
</div>
<?php
}
}
echo '</div>';
?>

<script>
    $(function(){
        $('.faq-description').hide();
        $('.panel-heading').on('click', function(){
            $('.faq-description.active').slideToggle(600).removeClass('active');
            $(this).next().slideToggle(600).toggleClass('active');

        });
    });
</script>
<?php
$text = ob_get_contents();
ob_clean();
ob_end_flush();
wp_reset_postdata();
    // echo $text;
return $text;
}
//team 
function teamShortCode($pageId = null, $isCustomizer = false, $i = null) { 

    ob_start();

    $args = array('post_type' => 'our-team');
    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    }
    $args['posts_per_page'] = -1;
    $colCls = '';
    // if($isCustomizer == true){
    $cols = get_theme_mod('luzuk_team_npp_count', 3);
    $cols++;
    switch($cols){
        case 1:
        $colCls = 'col-md-12 col-sm-12 col-xs-12';
        break;
        case 2:
        $colCls = 'col-md-6 col-sm-6 col-xs-12';
        break;
        case 3:
        case 5:
        case 6:
        $colCls = 'col-md-4 col-sm-6 col-xs-12';
        break;
        case 4:
        case 7:
        case 8:
        $colCls = 'col-md-3 col-sm-6 col-xs-12';
        break;
        default:
        $colCls = 'col-md-3 col-sm-6 col-xs-12';
        break;
    }

    // }
    $text = '';
    $query = new WP_Query($args);
    if ($query->have_posts()):
        $postN = 0;

        while ($query->have_posts()) : $query->the_post();
            $luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'total-team-thumb');
            if ($isCustomizer === true) {
                $luzuk_team_designation = get_theme_mod('luzuk_team_designation' . $i);
                $luzuk_team_facebook = get_theme_mod('luzuk_team_facebook' . $i);
                $luzuk_team_twitter = get_theme_mod('luzuk_team_twitter' . $i);
                $luzuk_team_linkedin = get_theme_mod('luzuk_team_linkedin' . $i);
                $luzuk_team_instagram = get_theme_mod('luzuk_team_instagram' . $i);
                $luzuk_team_googleplus = get_theme_mod('luzuk_team_googleplus' . $i);
            } else {
                $luzuk_team_facebook = '';
                $luzuk_team_twitter = '';
                $luzuk_team_linkedin = '';
                $luzuk_team_instagram = '';
                $luzuk_team_googleplus = '';
            }

            $post = get_post();
            //Social media urls
            $teamFacebook = get_post_meta($post->ID, 'teamFacebook', false);
            $luzuk_team_facebook = !empty($teamFacebook[0]) ? $teamFacebook[0] : '';
            $teamTwitter = get_post_meta($post->ID, 'teamTwitter', false);
            $luzuk_team_twitter = !empty($teamTwitter[0]) ? $teamTwitter[0] : '';
            // $teamGPlus = get_post_meta($post->ID, 'teamGPlus', false);
            // $luzuk_team_google_plus = !empty($teamGPlus[0]) ? $teamGPlus[0] : '';

            $teamInstagram = get_post_meta($post->ID, 'teamInstagram', false);
            $luzuk_team_instagram = !empty($teamInstagram[0]) ? $teamInstagram[0] : '';

            $teamlinkedIn = get_post_meta($post->ID, 'teamlinkedIn', false);
            $luzuk_team_linkedin = !empty($teamlinkedIn[0]) ? $teamlinkedIn[0] : '';

            $teamgoogleplus = get_post_meta($post->ID, 'teamgoogleplus', false);
            $luzuk_team_googleplus = !empty($teamgoogleplus[0]) ? $teamgoogleplus[0] : '';

            //designation
            $designation = get_post_meta($post->ID, 'designation', false);
            $luzuk_team_designation = !empty($designation[0]) ? $designation[0] : '';

            
            ?>
            <div class="row">
                <div class="<?php echo $colCls; ?>">


                    <div class="single-instructor-member mb-30">
                        <div class="member-image">
                           <?php
                           if (has_post_thumbnail()) {
                               $image_url = $luzuk_image[0];
                           } else {
                               $image_url = get_template_directory_uri() . '/images/team-thumb.png';
                           }
                           ?>     
                           <img src="<?php echo esc_url($image_url); ?>" alt="<?php the_title(); ?>" />
                       </div>
                       <div class="member-content">
                        <h3><a href=""><?php the_title(); ?></a></h3>
                        <span><?php echo ($luzuk_team_designation); ?></span>
                        <ul class="social">
                         <?php if ($luzuk_team_facebook || $luzuk_team_twitter || $luzuk_team_instagram || $luzuk_team_linkedin || $luzuk_team_googleplus) { ?>

                             <?php if ($luzuk_team_facebook) { ?>
                                 <li> <a target="_blank" href="<?php echo esc_url($luzuk_team_facebook) ?>" class="teamsocial green"><i class="fa fa-facebook"></i></a></li>
                             <?php } ?>
                             <?php if ($luzuk_team_twitter) { ?>
                                 <li> <a target="_blank" href="<?php echo esc_url($luzuk_team_twitter) ?>" class="teamsocial green"><i class="fa fa-twitter"></i></a></li>
                             <?php } ?>
                             <?php if ($luzuk_team_googleplus) { ?>
                                 <li>  <a target="_blank" href="<?php echo esc_url($luzuk_team_googleplus) ?>" class="teamsocial green"><i class="fa fa-google-plus"></i></a> </li>
                             <?php } ?>
                             <?php if ($luzuk_team_linkedin) { ?>
                                 <li>  <a target="_blank" href="<?php echo esc_url($luzuk_team_linkedin) ?>" class="teamsocial green"><i class="fa fa-linkedin"></i></a> </li>
                             <?php } ?>

                             <?php if ($luzuk_team_instagram) { ?>
                                 <li>   <a target="_blank" href="<?php echo esc_url($luzuk_team_instagram) ?>" class="teamsocial green"><i class="fa fa-instagram"></i></a> </li>
                             <?php } ?>
                         <?php } ?> 
                     </ul>
                 </div>
             </div>

             <!-- for innerpages -->
             <script>
                jQuery.noConflict();
                $(function(){
                    function singleinstructormemberHeight(){
                        var ht = 0;
                        $('#innerpage-box .single-instructor-member').each(function(i){
                            var tHt = $(this).height();
                            if(ht<tHt){
                                ht=tHt;
                            }
                        });
                        $('#innerpage-box .single-instructor-member').height(ht+'px');
                    }
                    singleinstructormemberHeight();
                });
                $( window ).resize(function(){
                    singleinstructormemberHeight();
                });
            </script>
            <!-- for innerpages -->


        </div>
        <?php
    endwhile;
    $text = ob_get_contents();
    ob_clean();
endif;
wp_reset_postdata();
return $text;
}
/**
 * Use for the show the testimonials at home page and in testimonial page with shortcode
 * @param int $pageId default is null the id of a post
 * @param boolean $isCustomizer default is false if set to true it mean the output is set for the home page
 * @param int $i default null
 * @param boolean $showStaticVals default is false
 * @return string
 * @author Luzuk <support@luzuk.com>
 * */


/*services*/
function ctserviceShortCode($pageId = null, $isCustomizer = false, $i = null) {
    ob_start();
    $args = array('post_type' => 'our-service'); 
    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    }
    $args['posts_per_page'] = -1;
    $colCls = '';
    // if($isCustomizer == true){
    $cols = get_theme_mod('luzuk_ct_service_npp_count',7);  
    $luzuk_ct_service_icon1 = get_theme_mod('luzuk_ct_service_icon1'.$i);
    ++$cols;
    switch ($cols) {
       case 1:
       $colCls = 'col-md-12 col-sm-12';
       break;
       case 2:
       $colCls = 'col-md-6 col-sm-6';
       break;        
       $colCls = 'col-md-2 col-sm-6';
       break;
       case 3:
       case 5:                             
       case 9:
       case 6: 
       case 4: 
       case 7:
       case 8:  
       case 10:
       case 11:
       case 12:
       case 13:
       case 14:
       case 15:
       case 16:
       case 17:
       case 18:
       $colCls = 'col-md-2 col-sm-6';
       break;
       default: 
       $colCls = 'col-md-2 col-sm-6';
       break;
   }
   $icons = array(1=>'heart', 2=>'star', 3=>'flash', 4=>'bell',5=>'heart', 6=>'star', 7=>'flash', 8=>'bell');  
    // }
   $text = '';
   $query = new WP_Query($args);
   if ($query->have_posts()):
    $postN = 0;

    while ($query->have_posts()) : $query->the_post();
        $luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'total-service-thumb');
        $post = get_post();
        ?>
        <div class="row">
            <div class="<?php echo $colCls; ?> complete-serbox">
               <div class="service-icon padding0 ">

                   <!-- <i class="<?php //echo $luzuk_ct_service_icon1; ?>"></i> -->
                   <a href="<?php the_permalink(); ?>">
                       <?php
                       if (has_post_thumbnail()) {
                        $image_url = $luzuk_image[0];
                    } else {
                        $image_url = get_template_directory_uri() . '/images/project.jpg';
                    }
                    ?>                                                          
                    <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="<?php the_title(); ?>" />
                </a>
            </div>
            <div class="serviceBox blue">

                <a href="<?php the_permalink(); ?>"> <h3 class="title"><?php the_title(); ?></h3> </a>

            </div>
            <div class="clearfix"></div>           

        </div>
        <?php
    endwhile;
    $text = ob_get_contents();
    ob_clean();
endif;
wp_reset_postdata();
return $text;
}
/*gallery*/

function galleryShortCode($pageId = null, $isCustomizer = false, $i = null) {

    ob_start();

    $args = array('post_type' => 'our_gallery');
    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    }
    $args['posts_per_page'] = -1;
    $colCls = '';
    // if($isCustomizer == true){
    $cols = get_theme_mod('lz_luzuk_gallery_npp_count', 19);  
    ++$cols;
    switch($cols){
        case 1:
        $colCls = 'col-md-12 col-sm-12';
        break;
        case 2:
        $colCls = 'col-md-6 col-sm-6';
        break;
        case 4:
        case 3:
        case 5:
        case 6:
        $colCls = 'col-md-3 col-sm-4';
        break;
        default: 
        $colCls = 'col-md-3 col-sm-4';
        break;
    }
    // }
    $text = '';
    $query = new WP_Query($args);
    if ($query->have_posts()):
        $postN = 0;

        while ($query->have_posts()) : $query->the_post();
            $lz_luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'medium_large');
            if ($isCustomizer === true) {
            } else {
                
            }

            $post = get_post();
            
            if (($postN % 3) == 0 && $isCustomizer == false) {
                ?>
                <div class="clearfix paddingBot20"></div>
            </div>
            <div class="row">
                <?php
            }
            ++$postN;
            ?>
            <div class="item <?php //echo $colCls; ?> gallery-img">
                <div class="ht-gallery-member">
                    <div class="gallery-image">
                        <?php
                        if (has_post_thumbnail()) {
                            $image_url = $lz_luzuk_image[0];
                        } else {
                            $image_url = get_template_directory_uri() . '/images/about1.jpg';
                        }
                        ?>
                        <a class="group1" href="<?php echo esc_url($image_url); ?>" title="<?php the_title(); ?>"> <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="" /> 
                            <div class="overlay-box"><h4><?php the_title(); ?></h4></div>                              

                        </a>
                    </div>

                    <?php ?>
                    <?php                                   
                    
                    ?>
                    
                </div>
                <div class="col-md-4 col-sm-6 gbox">
                    <div class=" gallerybox">
                       <?php
                       if (has_post_thumbnail()) {
                        $image_url = $lz_luzuk_image[0];
                    } else {
                        $image_url = get_template_directory_uri() . '/images/about1.jpg';
                    }
                    ?>
                    <a class="group1" href="<?php echo esc_url($image_url); ?>" title="<?php the_title(); ?>"> <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="" /> 
                    </a>
                    <div class="box-content">
                        <h3 class="title"><?php the_title(); ?></h3>                   
                    </div>
                    <ul class="icon">
                        <li><a class="group1" href="<?php echo esc_url($image_url); ?>" title="<?php the_title(); ?>"><i class="fa fa-search"></i></a></li>                    
                    </ul>
                </div><!--end -->
            </div>

        </div>

        <?php
    endwhile;
    $text = ob_get_contents();
    ob_clean();
endif;
wp_reset_postdata();
return $text;
}



    /**
     * Use for the show the testimonials at home page and in testimonial page with shortcode
     * @param int $pageId default is null the id of a post
     * @param boolean $isCustomizer default is false if set to true it mean the output is set for the home page
     * @param int $i default null
     * @param boolean $showStaticVals default is false
     * @return void
     * @author Luzuk <support@luzuk.com>
     * */
    

// for shortode
    function testimonialInnerShortCode($pageId = null, $isCustomizer = false, $i = null) {

        ob_start();

        $args = array('post_type' => 'ourtestimonial');
        if (!empty($pageId)) {
            $args['page_id'] = absint($pageId);
        }
        $colCls = '';
    // if($isCustomizer == true){
        $cols = get_theme_mod('lz_luzuk_test_npp_count', 2);
        $cols++;
        switch($cols){

        }
        $icons = array(1=>'heart', 2=>'star', 3=>'flash', 4=>'bell',5=>'heart', 6=>'star', 7=>'flash', 8=>'bell');     
    // }
        $text = '';
        $query = new WP_Query($args);
        if ($query->have_posts()):
            $postN = 0;

            while ($query->have_posts()) : $query->the_post();
                $lz_luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'total-team-thumb');
                if ($isCustomizer === true) {
                    $lz_luzuk_test_designation = get_theme_mod('lz_luzuk_test_designation' . $i);
                }
                $post = get_post();
            //designation
                $designation = get_post_meta($post->ID, 'designation', false);
                $lz_luzuk_test_designation = !empty($designation[0]) ? $designation[0] : '';

                if (($postN % 3) == 0 && $isCustomizer == false) {
                    ?>
                    <div class="clearfix paddingBot20"></div>
                </div>
                <div class="row">
                    <?php
                }
                ++$postN;
                ?>

                <div class="testimonial">
                    <div class="pic">
                        <img src="<?php echo (!empty($lz_luzuk_image[0])) ? $lz_luzuk_image[0] : get_template_directory_uri() . '/images/team-thumb.png' ?>" class="img-responsive" alt="<?php the_title(); ?>" />
                    </div>
                    <div class="testimonial-content">
                        <h3 class="testimonial-title">
                            <?php the_title(); ?> - <span><?php
                            $name2 = get_post_meta($post->ID, 'testimonial_Sub_Title', false);
                            echo (!empty($name2[0])) ? $name2[0] : '';
                            ?> 
                        </span>
                    </h3>
                    <p class="description">
                        <?php
                        if (has_excerpt()) {
                            echo get_the_excerpt();
                        } else {
                            echo get_the_content();
                        }
                        ?>
                    </p>
                </div>
            </div>
            <?php
        endwhile;
        $text = ob_get_contents();
        ob_clean();
    endif;
    wp_reset_postdata();
    return $text;
}


function testimonialShortCode($pageId = null, $isCustomizer = false, $i = null) {

    ob_start();

    $args = array('post_type' => 'ourtestimonial');
    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    }
    $colCls = '';
    // if($isCustomizer == true){
    $cols = get_theme_mod('lz_luzuk_test_npp_count', 2);
    $cols++;
    switch($cols){

    }
    $icons = array(1=>'heart', 2=>'star', 3=>'flash', 4=>'bell',5=>'heart', 6=>'star', 7=>'flash', 8=>'bell');     
    // }
    $text = '';
    $query = new WP_Query($args);
    if ($query->have_posts()):
        $postN = 0;

        while ($query->have_posts()) : $query->the_post();
            $lz_luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'total-team-thumb');
            if ($isCustomizer === true) {
                $lz_luzuk_test_designation = get_theme_mod('lz_luzuk_test_designation' . $i);
            }
            $post = get_post();
            //designation
            $designation = get_post_meta($post->ID, 'designation', false);
            $lz_luzuk_test_designation = !empty($designation[0]) ? $designation[0] : '';

            if (($postN % 3) == 0 && $isCustomizer == false) {
                ?>
                <div class="clearfix paddingBot20"></div>
            </div>
            <div class="row">
                <?php
            }
            ++$postN;
            ?>
            <div class="<?php echo $colCls; ?>">
                <div class="innerbor"></div>
                <div class="ht-test-member ">
                    <div class="test-content">
                      <div class="member-image col-md-6 padding0">
                          <img src="<?php echo (!empty($lz_luzuk_image[0])) ? $lz_luzuk_image[0] : get_template_directory_uri() . '/images/team-thumb.png' ?>" class="img-responsive" alt="<?php the_title(); ?>" />
                      </div>
                      <div class="testimonial-content">                      
                          <p><?php 
                          if(has_excerpt()){
                              echo get_the_excerpt();
                          }else{
                              echo luzuk_excerpt( get_the_content() , 150 );
                          }
                          ?></p>
                          <div class="clearfix"></div>   
                          <h6 class="member-name"><?php the_title(); ?></h6>
                          <div class="clearfix"></div> 
                      </div>
                      <div class="clearfix"></div> 
                  </div>   

                  <?php
                  ?> 

                  
                  <div class="clearfix"></div>
              </div>
          </div>
          <?php
      endwhile;
      $text = ob_get_contents();
      ob_clean();
  endif;
  wp_reset_postdata();
  return $text;
}

// Inner Shortcode Gallery

function galleryinnerShortcode($pageId = null, $isCustomizer = false, $i = null) {
  ob_start();
  $args = array('post_type' => 'our_gallery');
  if (!empty($pageId)) {
    $args['page_id'] = absint($pageId);
}
$args['posts_per_page'] = -1;
$colCls = '';
    // if($isCustomizer == true){
$cols = get_theme_mod('lz_luzuk_gallery_npp_count', 3);  
++$cols;
switch ($cols) {
}
    // }
$text = '';
$query = new WP_Query($args);
if ($query->have_posts()):
    $postN = 0;

    while ($query->have_posts()) : $query->the_post();
      $luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'medium_large');
      if ($isCustomizer === true) {
      } else {
      }
      $post = get_post();
      ?> 
      <div class="row">
        <!-- for innerpage -->
        <div class="col-md-3 col-sm-6 col-xs-12 padding5px">
            <figure class="main-inner-gallbx blue">
             <?php
             if (has_post_thumbnail()) {
                $image_url = $luzuk_image[0];
            } else {
                $image_url = get_template_directory_uri() . '/images/about1.jpg';
            }
            ?>
            <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="<?php the_title(); ?>" />
            <figcaption>
                <div><i class="fa fa-plus"></i></div>
            </figcaption> <a class="group1" href="<?php echo esc_url($image_url); ?>" title="<?php the_title(); ?>"></a>
        </figure>
    </div>

    <!-- for innerpage -->

    <?php  ?>
    <?php                                   
    ?>

    <?php
endwhile;
$text = ob_get_contents();
ob_clean();
endif;
wp_reset_postdata();
return $text;
}


// Services Shortcode:
function serviceInnerShortCode($pageId = null, $isCustomizer = false, $i = null) {
    ob_start();
    $args = array('post_type' => 'our-service'); 
    if (!empty($pageId)) {
        $args['page_id'] = absint($pageId);
    }
    $args['posts_per_page'] = -1;
    $colCls = '';
    // if($isCustomizer == true){
    $cols = get_theme_mod('luzuk_ct_service_npp_count',7);  
    $luzuk_ct_service_icon1 = get_theme_mod('luzuk_ct_service_icon1'.$i);
    ++$cols;
    switch ($cols) {
    }
    $icons = array(1=>'heart', 2=>'star', 3=>'flash', 4=>'bell',5=>'heart', 6=>'star', 7=>'flash', 8=>'bell');  
    $text = '';
    $query = new WP_Query($args);
    if ($query->have_posts()):
        $postN = 0;

        while ($query->have_posts()) : $query->the_post();
            $luzuk_image = wp_get_attachment_image_src(get_post_thumbnail_id(), 'total-service-thumb');
            $post = get_post();
            ?>
            <div class="row">
                <div class="col-md-3 col-sm-6 col-xs-12">
                    <figure class="services-inner-wrapper">
                       <?php
                       if (has_post_thumbnail()) {
                        $image_url = $luzuk_image[0];
                    } else {
                        $image_url = get_template_directory_uri() . '/images/project.jpg';
                    }
                    ?>                                                          
                    <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="<?php the_title(); ?>" />

                    <img class="secondry-bg img-responsive" src="<?php echo esc_url($image_url); ?>" alt="<?php the_title(); ?>" />
                    <figcaption>
                        <h3><?php the_title(); ?></h3>
                    </figcaption>
                    <a href="<?php the_permalink(); ?>"></a>
                </figure>
            </div>
            <?php
        endwhile;
        $text = ob_get_contents();
        ob_clean();
    endif;
    wp_reset_postdata();
    return $text;
}



//adding a shortcode for the team / trainer list 
add_shortcode('TEAMLIST', 'teamShortCode');
add_shortcode('TESTIMONIALS', 'testimonialInnerShortCode');

add_shortcode('GALLERY', 'galleryinnerShortcode'); 

add_shortcode('FAQS', 'faqShortcode');

add_shortcode('SERVICES', 'serviceInnerShortCode');


