| 1 |
<?php |
| 2 |
/** |
| 3 |
* Template for displaying Continue button in single course. |
| 4 |
* |
| 5 |
* This template can be overridden by copying it to yourtheme/learnpress/single-course/buttons/continue.php. |
| 6 |
* |
| 7 |
* @author ThimPress |
| 8 |
* @package Learnpress/Templates |
| 9 |
* @version 4.0.1 |
| 10 |
*/ |
| 11 |
|
| 12 |
defined( 'ABSPATH' ) || exit(); |
| 13 |
|
| 14 |
$course = learn_press_get_course(); |
| 15 |
if ( ! $course ) { |
| 16 |
return; |
| 17 |
} |
| 18 |
?> |
| 19 |
|
| 20 |
<form name="course-external-link" class="course-external-link form-button lp-form" method="post" target="_blank"> |
| 21 |
|
| 22 |
<input type="hidden" name="lp-ajax" value="external-link"> |
| 23 |
<input type="hidden" name="id" value="<?php echo esc_attr( $course->get_id() ); ?>"> |
| 24 |
<input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'external-link-' . $course->get_external_link() ); ?>"> |
| 25 |
<button type="submit" class="lp-button button"> |
| 26 |
<?php echo esc_html( apply_filters( 'learn-press/external-course-button-text', esc_html( $course->get_external_link_text() )) ); ?> |
| 27 |
</button> |
| 28 |
|
| 29 |
</form> |
| 30 |
|