enrolled
3 years ago
add-to-cart-edd.php
4 years ago
add-to-cart-woocommerce.php
3 years ago
continue-lesson.php
4 years ago
course-benefits.php
4 years ago
course-content.php
4 years ago
course-entry-box.php
3 years ago
course-requirements.php
4 years ago
course-target-audience.php
4 years ago
course-topics.php
3 years ago
instructors.php
3 years ago
lead-info.php
3 years ago
material-includes.php
4 years ago
q_and_a_turned_off.php
4 years ago
reviews-loop.php
3 years ago
reviews.php
3 years ago
social_share.php
4 years ago
tags.php
3 years ago
wc-price-html.php
4 years ago
course-content.php
51 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Template for displaying course content |
| 5 | * |
| 6 | * @since v.1.0.0 |
| 7 | * |
| 8 | * @author Themeum |
| 9 | * @url https://themeum.com |
| 10 | * |
| 11 | * @package TutorLMS/Templates |
| 12 | * @version 1.4.3 |
| 13 | */ |
| 14 | |
| 15 | global $post; |
| 16 | |
| 17 | do_action('tutor_course/single/before/content'); |
| 18 | |
| 19 | if (tutor_utils()->get_option('enable_course_about', true, true)) { |
| 20 | $string = apply_filters( 'tutor_course_about_content', get_the_content() ); |
| 21 | $content_summary = (bool) get_tutor_option( 'course_content_summary', true ); |
| 22 | $post_size_in_words = sizeof( explode(" ", $string) ); |
| 23 | $word_limit = 100; |
| 24 | $has_show_more = false; |
| 25 | |
| 26 | if ( $content_summary && ( $post_size_in_words > $word_limit ) ) { |
| 27 | $has_show_more = true; |
| 28 | } |
| 29 | ?> |
| 30 | <?php if ( !empty($string) ) : ?> |
| 31 | <div class="tutor-course-details-content<?php echo $has_show_more ? ' tutor-toggle-more-content tutor-toggle-more-collapsed' : '' ?>"<?php echo $has_show_more ? ' data-tutor-toggle-more-content data-toggle-height="200" style="height: 200px;"' : '' ?>> |
| 32 | <h2 class="tutor-fs-5 tutor-fw-bold tutor-color-black tutor-mb-12"> |
| 33 | <?php echo apply_filters( 'tutor_course_about_title', __( 'About Course', 'tutor' ) ); ?> |
| 34 | </h2> |
| 35 | |
| 36 | <div class="tutor-fs-6 tutor-color-secondary"> |
| 37 | <?php echo apply_filters( 'the_content', $string ); ?> |
| 38 | </div> |
| 39 | </div> |
| 40 | |
| 41 | <?php if ( $has_show_more ) : ?> |
| 42 | <a href="#" class="tutor-btn-show-more tutor-btn tutor-btn-ghost tutor-mt-32" data-tutor-toggle-more=".tutor-toggle-more-content"> |
| 43 | <span class="tutor-toggle-btn-icon tutor-icon tutor-icon-plus tutor-mr-8" area-hidden="true"></span> |
| 44 | <span class="tutor-toggle-btn-text"><?php esc_html_e( 'Show More', 'tutor' ); ?></span> |
| 45 | </a> |
| 46 | <?php endif; ?> |
| 47 | <?php endif; ?> |
| 48 | <?php |
| 49 | } |
| 50 | |
| 51 | do_action('tutor_course/single/after/content'); ?> |