@@ -56,7 +56,8 @@ discard block |
||
56 | 56 | } |
57 | 57 | |
58 | 58 | private function translate_settings( $settings ) { |
59 | - if ( $settings ) { //workaround for W3 total cache conflict |
|
59 | + if ( $settings ) { |
|
60 | +//workaround for W3 total cache conflict |
|
60 | 61 | return unserialize( serialize( $settings ) ); |
61 | 62 | } |
62 | 63 | |
@@ -68,7 +69,8 @@ discard block |
||
68 | 69 | } |
69 | 70 | |
70 | 71 | // If unserializing didn't work |
71 | - if ( $settings ) { //workaround for W3 total cache conflict |
|
72 | + if ( $settings ) { |
|
73 | +//workaround for W3 total cache conflict |
|
72 | 74 | $settings = unserialize( serialize( $settings ) ); |
73 | 75 | } else { |
74 | 76 | $settings = $this; |
@@ -78,7 +78,8 @@ |
||
78 | 78 | |
79 | 79 | if ( ! isset( $imported['form_status'] ) || empty( $imported['form_status'] ) ) { |
80 | 80 | // Check for an error message in the XML. |
81 | - if ( isset( $xml->Code ) && isset( $xml->Message ) ) { // phpcs:ignore WordPress.NamingConventions |
|
81 | + if ( isset( $xml->Code ) && isset( $xml->Message ) ) { |
|
82 | +// phpcs:ignore WordPress.NamingConventions |
|
82 | 83 | $imported['error'] = reset( $xml->Message ); // phpcs:ignore WordPress.NamingConventions |
83 | 84 | } |
84 | 85 | } |
@@ -39,7 +39,8 @@ |
||
39 | 39 | } |
40 | 40 | |
41 | 41 | foreach ( $sub_field['options'] as $option ) { |
42 | - if ( 'default_value' === $option ) { // We parse default value from field column. |
|
42 | + if ( 'default_value' === $option ) { |
|
43 | +// We parse default value from field column. |
|
43 | 44 | continue; |
44 | 45 | } |
45 | 46 |
@@ -122,7 +122,8 @@ |
||
122 | 122 | |
123 | 123 | private static function field_headings( $col ) { |
124 | 124 | $field_type_obj = FrmFieldFactory::get_field_factory( $col ); |
125 | - if ( ! empty( $field_type_obj->is_combo_field ) ) { // This is combo field. |
|
125 | + if ( ! empty( $field_type_obj->is_combo_field ) ) { |
|
126 | +// This is combo field. |
|
126 | 127 | return $field_type_obj->get_export_headings(); |
127 | 128 | } |
128 | 129 |
@@ -42,7 +42,8 @@ |
||
42 | 42 | } |
43 | 43 | |
44 | 44 | // Only do this for single site installs. |
45 | - if ( isset( $_GET['activate-multi'] ) || is_network_admin() ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
45 | + if ( isset( $_GET['activate-multi'] ) || is_network_admin() ) { |
|
46 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
46 | 47 | return; |
47 | 48 | } |
48 | 49 |
@@ -1465,7 +1465,8 @@ discard block |
||
1465 | 1465 | $vars = array(); |
1466 | 1466 | FrmAppHelper::include_svg(); |
1467 | 1467 | |
1468 | - if ( isset( $_POST['frm_compact_fields'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1468 | + if ( isset( $_POST['frm_compact_fields'] ) ) { |
|
1469 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1469 | 1470 | FrmAppHelper::permission_check( 'frm_edit_forms' ); |
1470 | 1471 | |
1471 | 1472 | // Javascript needs to be allowed in some field settings. |
@@ -1735,7 +1736,8 @@ discard block |
||
1735 | 1736 | private static function maybe_get_form_to_show( $id ) { |
1736 | 1737 | $form = false; |
1737 | 1738 | |
1738 | - if ( ! empty( $id ) ) { // no form id or key set |
|
1739 | + if ( ! empty( $id ) ) { |
|
1740 | +// no form id or key set |
|
1739 | 1741 | $form = FrmForm::getOne( $id ); |
1740 | 1742 | if ( ! $form || $form->parent_form_id || $form->status == 'trash' ) { |
1741 | 1743 | $form = false; |
@@ -1817,7 +1819,8 @@ discard block |
||
1817 | 1819 | private static function get_saved_errors( $form, $params ) { |
1818 | 1820 | global $frm_vars; |
1819 | 1821 | |
1820 | - if ( $params['posted_form_id'] == $form->id && $_POST && isset( $frm_vars['created_entries'][ $form->id ] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1822 | + if ( $params['posted_form_id'] == $form->id && $_POST && isset( $frm_vars['created_entries'][ $form->id ] ) ) { |
|
1823 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1821 | 1824 | $errors = $frm_vars['created_entries'][ $form->id ]['errors']; |
1822 | 1825 | } else { |
1823 | 1826 | $errors = array(); |
@@ -491,7 +491,8 @@ |
||
491 | 491 | |
492 | 492 | public static function process_entry( $errors = '', $ajax = false ) { |
493 | 493 | $form_id = FrmAppHelper::get_post_param( 'form_id', '', 'absint' ); |
494 | - if ( FrmAppHelper::is_admin() || empty( $_POST ) || empty( $form_id ) || ! isset( $_POST['item_key'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
494 | + if ( FrmAppHelper::is_admin() || empty( $_POST ) || empty( $form_id ) || ! isset( $_POST['item_key'] ) ) { |
|
495 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
495 | 496 | return; |
496 | 497 | } |
497 | 498 |
@@ -367,7 +367,8 @@ discard block |
||
367 | 367 | |
368 | 368 | if ( isset( $version_info->new_version ) && ! empty( $version_info->new_version ) ) { |
369 | 369 | $this->clear_old_plugin_version( $version_info ); |
370 | - if ( $version_info === false ) { // was cleared with timeout |
|
370 | + if ( $version_info === false ) { |
|
371 | +// was cleared with timeout |
|
371 | 372 | $transient = false; |
372 | 373 | } else { |
373 | 374 | $this->maybe_use_beta_url( $version_info ); |
@@ -455,7 +456,8 @@ discard block |
||
455 | 456 | } |
456 | 457 | |
457 | 458 | private function is_license_revoked() { |
458 | - if ( empty( $this->license ) || empty( $this->plugin_slug ) || isset( $_POST['license'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
459 | + if ( empty( $this->license ) || empty( $this->plugin_slug ) || isset( $_POST['license'] ) ) { |
|
460 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
459 | 461 | return; |
460 | 462 | } |
461 | 463 |
@@ -180,7 +180,8 @@ discard block |
||
180 | 180 | * @param mixed $value |
181 | 181 | */ |
182 | 182 | private static function get_posted_field_setting( $setting, &$value ) { |
183 | - if ( ! isset( $_POST['field_options'][ $setting ] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
183 | + if ( ! isset( $_POST['field_options'][ $setting ] ) ) { |
|
184 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
184 | 185 | return; |
185 | 186 | } |
186 | 187 | |
@@ -1084,7 +1085,8 @@ discard block |
||
1084 | 1085 | |
1085 | 1086 | // Check posted vals before checking saved values |
1086 | 1087 | // For fields inside repeating sections - note, don't check if $pointer is true because it will often be zero |
1087 | - if ( $parent && isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1088 | + if ( $parent && isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] ) ) { |
|
1089 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1088 | 1090 | if ( FrmField::is_field_with_multiple_values( $field ) ) { |
1089 | 1091 | // phpcs:ignore WordPress.Security.NonceVerification.Missing |
1090 | 1092 | $other_val = isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ][ $opt_key ] ) ? sanitize_text_field( wp_unslash( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ][ $opt_key ] ) ) : ''; |
@@ -1094,7 +1096,8 @@ discard block |
||
1094 | 1096 | |
1095 | 1097 | return $other_val; |
1096 | 1098 | |
1097 | - } elseif ( isset( $field['id'] ) && isset( $_POST['item_meta']['other'][ $field['id'] ] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1099 | + } elseif ( isset( $field['id'] ) && isset( $_POST['item_meta']['other'][ $field['id'] ] ) ) { |
|
1100 | +// phpcs:ignore WordPress.Security.NonceVerification.Missing |
|
1098 | 1101 | // For normal fields |
1099 | 1102 | |
1100 | 1103 | if ( FrmField::is_field_with_multiple_values( $field ) ) { |