comment.php
3 years ago
comments-loop.php
3 years ago
complete_form.php
2 years ago
content.php
2 years ago
lesson_sidebar.php
2 years ago
required-enroll.php
2 years ago
sidebar_question_and_answer.php
3 years ago
complete_form.php
36 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Display attachments |
| 4 | * |
| 5 | * @package Tutor\Templates |
| 6 | * @subpackage Single\Lesson |
| 7 | * @author Themeum <support@themeum.com> |
| 8 | * @link https://themeum.com |
| 9 | * @since 1.0.0 |
| 10 | */ |
| 11 | |
| 12 | if ( ! defined( 'ABSPATH' ) ) { |
| 13 | exit; |
| 14 | } |
| 15 | |
| 16 | do_action( 'tutor_lesson/single/before/complete_form' ); |
| 17 | |
| 18 | $is_completed_lesson = tutor_utils()->is_completed_lesson(); |
| 19 | if ( ! $is_completed_lesson ) { |
| 20 | ?> |
| 21 | <div class="tutor-topbar-complete-btn tutor-mr-20"> |
| 22 | <form method="post"> |
| 23 | <?php wp_nonce_field( tutor()->nonce_action, tutor()->nonce, false ); ?> |
| 24 | <input type="hidden" value="<?php echo esc_attr( get_the_ID() ); ?>" name="lesson_id" /> |
| 25 | <input type="hidden" value="tutor_complete_lesson" name="tutor_action" /> |
| 26 | <button type="submit" class="tutor-topbar-mark-btn tutor-btn tutor-btn-primary tutor-ws-nowrap" |
| 27 | name="complete_lesson_btn" value="complete_lesson"> |
| 28 | <span class="tutor-icon-circle-mark-line tutor-mr-8" area-hidden="true"></span> |
| 29 | <span><?php esc_html_e( 'Mark as Complete', 'tutor' ); ?></span> |
| 30 | </button> |
| 31 | </form> |
| 32 | </div> |
| 33 | <?php |
| 34 | } |
| 35 | do_action( 'tutor_lesson/single/after/complete_form' ); ?> |
| 36 |