PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.18
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.18
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/views/frm-entries/errors.php +2 -17 6.336.18 View file →
@@ -1,16 +1,5 @@
1 1 <?php
2 -/**
3 - * Form errors and success message wrapper.
4 - *
5 - * @package Formidable
6 - *
7 - * @var stdClass|null $form Form object when available.
8 - * @var string|null $message Success message HTML.
9 - * @var array|null $errors Field errors keyed by field id.
10 - * @var string|null $include_extra_container Optional CSS class for a wrapping container.
11 - */
12 -
13 2 if ( ! defined( 'ABSPATH' ) ) {
14 3 die( 'You are not allowed to call this page directly.' );
15 4 }
16 5
@@ -17,10 +6,8 @@
17 6 if ( isset( $include_extra_container ) ) { ?>
18 7 <div class="<?php echo esc_attr( $include_extra_container ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container">
19 8 <?php
20 9 }
21 -
22 -// phpcs:ignore Universal.Operators.StrictComparisons
23 10 if ( isset( $message ) && $message != '' ) {
24 11 if ( FrmAppHelper::is_admin() ) {
25 12 ?>
26 13 <div id="message" class="frm_updated_message" role="status"><?php echo wp_kses_post( $message ); ?></div>
@@ -27,9 +14,9 @@
27 14 <?php
28 15 } else {
29 16 FrmFormsHelper::maybe_get_scroll_js( $form->id );
30 17
31 - // We need to allow scripts here for javascript in the success message
18 + // we need to allow scripts here for javascript in the success message
32 19 echo FrmAppHelper::maybe_kses( $message ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
33 20 }
34 21 }
35 22
@@ -40,13 +27,11 @@
40 27 ?>
41 28 <div class="<?php echo esc_attr( FrmFormsHelper::form_error_class() ); ?>" role="alert">
42 29 <?php
43 30 $img = '';
44 -
45 31 if ( ! FrmAppHelper::is_admin() ) {
46 32 $img = apply_filters( 'frm_error_icon', $img );
47 -
48 - if ( $img ) {
33 + if ( $img && ! empty( $img ) ) {
49 34 echo '<img src="' . esc_url( $img ) . '" alt="" />';
50 35 }
51 36 }
52 37