| @@ -1,86 +1,86 @@ | ||
| 1 | -<?php | |
| 2 | -/** | |
| 3 | - * Template for displaying instructor of single course. | |
| 4 | - * | |
| 5 | - * This template can be overridden by copying it to yourtheme/learnpress/single-course/instructor.php. | |
| 6 | - * | |
| 7 | - * @author ThimPress | |
| 8 | - * @package Learnpress/Templates | |
| 9 | - * @version 3.3.1 | |
| 10 | - */ | |
| 11 | - | |
| 12 | -use LearnPress\TemplateHooks\Instructor\SingleInstructorTemplate; | |
| 13 | - | |
| 14 | -defined( 'ABSPATH' ) || exit(); | |
| 15 | - | |
| 16 | -$course = learn_press_get_course(); | |
| 17 | -if ( ! $course ) { | |
| 18 | - return; | |
| 19 | -} | |
| 20 | -/** | |
| 21 | - * @var LP_User $instructor | |
| 22 | - */ | |
| 23 | -$instructor = $course->get_instructor(); | |
| 24 | -$singleInstructorTemplate = SingleInstructorTemplate::instance(); | |
| 25 | -?> | |
| 26 | - | |
| 27 | -<div class="course-author"> | |
| 28 | - | |
| 29 | - <?php do_action( 'learn-press/before-single-course-instructor' ); ?> | |
| 30 | - | |
| 31 | - <div class="lp-course-author"> | |
| 32 | - <div class="course-author__pull-left"> | |
| 33 | - <?php echo wp_kses_post( $instructor->get_profile_picture() ); ?> | |
| 34 | - </div> | |
| 35 | - | |
| 36 | - <div class="course-author__pull-right"> | |
| 37 | - <h4 class="author-title"><?php echo wp_kses_post( $course->get_instructor_html() ); ?></h4> | |
| 38 | - <?php | |
| 39 | - echo $singleInstructorTemplate->html_social( $instructor ); | |
| 40 | - ?> | |
| 41 | - <div class="author-description"> | |
| 42 | - | |
| 43 | - <?php | |
| 44 | - /** | |
| 45 | - * LP Hook | |
| 46 | - * | |
| 47 | - * @since 4.0.0 | |
| 48 | - */ | |
| 49 | - do_action( 'learn-press/begin-course-instructor-description', $instructor ); | |
| 50 | - | |
| 51 | - echo wp_kses_post( $instructor->get_description() ); | |
| 52 | - | |
| 53 | - /** | |
| 54 | - * LP Hook | |
| 55 | - * | |
| 56 | - * @since 4.0.0 | |
| 57 | - */ | |
| 58 | - do_action( 'learn-press/end-course-instructor-description', $instructor ); | |
| 59 | - | |
| 60 | - ?> | |
| 61 | - </div> | |
| 62 | - | |
| 63 | - <?php | |
| 64 | - /** | |
| 65 | - * LP Hook | |
| 66 | - * | |
| 67 | - * @since 4.0.0 | |
| 68 | - */ | |
| 69 | - do_action( 'learn-press/after-course-instructor-description', $instructor ); | |
| 70 | - ?> | |
| 71 | - | |
| 72 | - <?php | |
| 73 | - | |
| 74 | - /** | |
| 75 | - * LP Hook | |
| 76 | - * | |
| 77 | - * @since 4.0.0 | |
| 78 | - */ | |
| 79 | - do_action( 'learn-press/after-course-instructor-socials', $instructor ); | |
| 80 | - | |
| 81 | - ?> | |
| 82 | - </div> | |
| 83 | - </div> | |
| 84 | - <?php do_action( 'learn-press/after-single-course-instructor' ); ?> | |
| 85 | - | |
| 86 | -</div> | |
| 1 | +<?php | |
| 2 | +/** | |
| 3 | + * Template for displaying instructor of single course. | |
| 4 | + * | |
| 5 | + * This template can be overridden by copying it to yourtheme/learnpress/single-course/instructor.php. | |
| 6 | + * | |
| 7 | + * @author ThimPress | |
| 8 | + * @package Learnpress/Templates | |
| 9 | + * @version 3.3.1 | |
| 10 | + */ | |
| 11 | + | |
| 12 | +use LearnPress\TemplateHooks\Instructor\SingleInstructorTemplate; | |
| 13 | + | |
| 14 | +defined( 'ABSPATH' ) || exit(); | |
| 15 | + | |
| 16 | +$course = learn_press_get_course(); | |
| 17 | +if ( ! $course ) { | |
| 18 | + return; | |
| 19 | +} | |
| 20 | +/** | |
| 21 | + * @var LP_User $instructor | |
| 22 | + */ | |
| 23 | +$instructor = $course->get_instructor(); | |
| 24 | +$singleInstructorTemplate = SingleInstructorTemplate::instance(); | |
| 25 | +?> | |
| 26 | + | |
| 27 | +<div class="course-author"> | |
| 28 | + | |
| 29 | + <?php do_action( 'learn-press/before-single-course-instructor' ); ?> | |
| 30 | + | |
| 31 | + <div class="lp-course-author"> | |
| 32 | + <div class="course-author__pull-left"> | |
| 33 | + <?php echo wp_kses_post( $instructor->get_profile_picture() ); ?> | |
| 34 | + </div> | |
| 35 | + | |
| 36 | + <div class="course-author__pull-right"> | |
| 37 | + <h4 class="author-title"><?php echo wp_kses_post( $course->get_instructor_html() ); ?></h4> | |
| 38 | + <?php | |
| 39 | + echo $singleInstructorTemplate->html_social( $instructor ); | |
| 40 | + ?> | |
| 41 | + <div class="author-description"> | |
| 42 | + | |
| 43 | + <?php | |
| 44 | + /** | |
| 45 | + * LP Hook | |
| 46 | + * | |
| 47 | + * @since 4.0.0 | |
| 48 | + */ | |
| 49 | + do_action( 'learn-press/begin-course-instructor-description', $instructor ); | |
| 50 | + | |
| 51 | + echo wp_kses_post( $instructor->get_description() ); | |
| 52 | + | |
| 53 | + /** | |
| 54 | + * LP Hook | |
| 55 | + * | |
| 56 | + * @since 4.0.0 | |
| 57 | + */ | |
| 58 | + do_action( 'learn-press/end-course-instructor-description', $instructor ); | |
| 59 | + | |
| 60 | + ?> | |
| 61 | + </div> | |
| 62 | + | |
| 63 | + <?php | |
| 64 | + /** | |
| 65 | + * LP Hook | |
| 66 | + * | |
| 67 | + * @since 4.0.0 | |
| 68 | + */ | |
| 69 | + do_action( 'learn-press/after-course-instructor-description', $instructor ); | |
| 70 | + ?> | |
| 71 | + | |
| 72 | + <?php | |
| 73 | + | |
| 74 | + /** | |
| 75 | + * LP Hook | |
| 76 | + * | |
| 77 | + * @since 4.0.0 | |
| 78 | + */ | |
| 79 | + do_action( 'learn-press/after-course-instructor-socials', $instructor ); | |
| 80 | + | |
| 81 | + ?> | |
| 82 | + </div> | |
| 83 | + </div> | |
| 84 | + <?php do_action( 'learn-press/after-single-course-instructor' ); ?> | |
| 85 | + | |
| 86 | +</div> | |