<div class="ulp-course-review-list-wrapp">
    <?php if (!empty($data['items'])):?>
        <h2><?php _e('Course Reviews', 'ulp');?></h2>
        <div class="ulp-course-review-list">
        <?php foreach ($data['items'] as $object):?>
            <?php
                $fullName = $object->full_name;
                $authorImage = $object->authorImage;
                $stars = $object->stars;
                $createdTime = $object->created_time;
                $title = $object->title;
                $content = $object->content;
            ?>
            <?php include $data['single_course_review_template'];?>
        <?php endforeach;?>
      </div>
      <?php if ($data['showMore']):?>
           <div class="ulp-load-more-bttn-wrapp">
          	<div class="ulp-load-more-bttn" id="ulp_course_reviews_load_more" ><?php _e('Show More', 'ulp');?></div>
      		</div>
	  <?php endif;?>
    <?php else:?>
        <div class="ulp-additional-message"><?php _e('No Reviews avaialable for this course', 'ulp');?></div>
    <?php endif;?>
</div>
<?php if ($data['showMore']):?>

  <script src="<?php echo ULP_URL . 'assets/js/course_reviews.js';?>" type="text/javascript"></script>
  <script>
      jQuery(document).ready(function(){
          UlpReviews.init({
                offset: 10,
                slug: '<?php echo $data['post_slug'];?>',
                hash: '<?php echo md5($data['post_slug'] . 'ulp_secret');?>',
                wrapper: '.ulp-course-review-list'
          });
      });
  </script>

<?php endif;?>
