| @@ -1,5 +1,13 @@ | ||
| 1 | 1 | <?php |
| 2 | +/** | |
| 3 | + * CAPTCHA field form builder view. | |
| 4 | + * | |
| 5 | + * @package Formidable | |
| 6 | + * | |
| 7 | + * @var string $field_name HTML name attribute for the hidden input. | |
| 8 | + */ | |
| 9 | + | |
| 2 | 10 | if ( ! defined( 'ABSPATH' ) ) { |
| 3 | 11 | die( 'You are not allowed to call this page directly.' ); |
| 4 | 12 | } |
| 5 | 13 | |
| @@ -5,9 +13,9 @@ | ||
| 5 | 13 | |
| 6 | 14 | if ( ! FrmFieldCaptcha::should_show_captcha() ) { |
| 7 | 15 | ?> |
| 8 | 16 | <span class="frm-with-icon frm-not-set frm_note_style"> |
| 9 | - <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_report_problem_solid_icon' ); ?> | |
| 17 | + <?php FrmAppHelper::icon_by_class( 'frmfont frm_report_problem_solid_icon' ); ?> | |
| 10 | 18 | <?php esc_attr_e( 'This field is not set up yet.', 'formidable' ); ?> |
| 11 | 19 | </span> |
| 12 | 20 | <?php |
| 13 | 21 | return; |
| @@ -13,7 +21,8 @@ | ||
| 13 | 21 | return; |
| 14 | 22 | } |
| 15 | 23 | |
| 16 | 24 | $image_name = FrmFieldCaptcha::get_captcha_image_name(); |
| 25 | +$extension = 'turnstile' === $image_name ? 'gif' : 'png'; | |
| 17 | 26 | ?> |
| 18 | -<img src="<?php echo esc_url( FrmAppHelper::plugin_url() . '/images/' . $image_name . '.png' ); ?>" class="<?php echo esc_attr( $image_name ); ?>_placeholder" alt="<?php echo esc_attr( $image_name ); ?>"/> | |
| 27 | +<img src="<?php echo esc_url( FrmAppHelper::plugin_url() . '/images/' . $image_name . '.' . $extension ); ?>" class="<?php echo esc_attr( $image_name ); ?>_placeholder" alt="<?php echo esc_attr( $image_name ); ?>"/> | |
| 19 | 28 | <input type="hidden" name="<?php echo esc_attr( $field_name ); ?>" value="1" /> |