| 1 |
<?php |
| 2 |
/** |
| 3 |
* Outputs the restricted content product email field |
| 4 |
* for the subscriber to enter their email address if |
| 5 |
* they've already subscribed to the ConvertKit resource. |
| 6 |
* |
| 7 |
* @package ConvertKit |
| 8 |
* @author ConvertKit |
| 9 |
*/ |
| 10 |
|
| 11 |
// If scripts are disabled in the Plugin's settings, output the email login form now. |
| 12 |
if ( $this->settings->scripts_disabled() ) { |
| 13 |
?> |
| 14 |
<p> |
| 15 |
<?php echo esc_html( $this->restrict_content_settings->get_by_key( 'email_text' ) ); ?> |
| 16 |
</p> |
| 17 |
<?php |
| 18 |
require 'login-email.php'; |
| 19 |
} else { |
| 20 |
// Just output the paragraph with a link to login, which will trigger the modal to display. |
| 21 |
?> |
| 22 |
<p> |
| 23 |
<?php echo esc_html( $this->restrict_content_settings->get_by_key( 'email_text' ) ); ?> |
| 24 |
<a href="#" class="convertkit-restrict-content-modal-open"><?php echo esc_attr( $this->restrict_content_settings->get_by_key( 'email_button_label' ) ); ?></a> |
| 25 |
</p> |
| 26 |
<?php |
| 27 |
} |