Formidable Forms – Form Builder for WordPress - Version 4.0.02

Version Description

  • Include the WordPress admin bar in full screen mode.
  • Replace field icons in builder with svg sprite to prevent browser caching issues.
  • Update the field ids in more of the form action settings when a form is duplicated.
  • Live update for default values.
  • Click on a field description on the form builder page to be taken directly to the setting.
  • Allow apostrophes in an email address.
  • Save a few clicks. Move the layout classes out of the advanced section and auto open the fields class list on click. Also select the search box when the form switcher is selected.
  • Fix: The WordPress menu was collapsed when editing a post. Oops!
  • Fix: Trim whitespace from radio/checkbox/dropdown options when they are changed.
  • Fix: Automatically hide and show the field box more accurately when clicking in and out of settings that use it.
  • Fix: Include field selection box on the redirect url setting.
  • Fix: Adjust the show entry page for small screens.
  • Fix: After an entry was deleted from the entry listing page, the page no longer scrolled.
  • Fix: Backslashes were removed in the Custom CSS on save.
  • Fix: In some cases, the default value was showing as a placeholder.
  • Fix: Fix a PHP 5.4 error. If you are running a version less than 5.6, you'll see a reminder message to get up to date.
  • Code: Added a trigger for use after an ajax call. The frmElementAdded trigger allows add-ons to add the field box menu to newly added settings.
  • Show a message if Internet Explorer is being used. This browser is no longer supported in the form builder.
Download this release

Release Info

Developer sswells
Plugin Icon 128x128 Formidable Forms – Form Builder for WordPress
Version 4.0.02
Comparing to
See all releases

Code changes from version 4.0.01 to 4.0.02

Files changed (69) hide show
  1. classes/controllers/FrmAddonsController.php +2 -0
  2. classes/controllers/FrmAppController.php +4 -21
  3. classes/controllers/FrmEntriesController.php +2 -1
  4. classes/controllers/FrmFormActionsController.php +8 -0
  5. classes/controllers/FrmFormsController.php +5 -7
  6. classes/controllers/FrmHooksController.php +0 -1
  7. classes/controllers/FrmSettingsController.php +14 -1
  8. classes/controllers/FrmStylesController.php +1 -0
  9. classes/controllers/FrmXMLController.php +4 -2
  10. classes/helpers/FrmAppHelper.php +106 -2
  11. classes/helpers/FrmEntriesHelper.php +5 -5
  12. classes/helpers/FrmEntriesListHelper.php +7 -0
  13. classes/helpers/FrmFieldsHelper.php +14 -10
  14. classes/helpers/FrmFormsHelper.php +4 -4
  15. classes/helpers/FrmFormsListHelper.php +7 -1
  16. classes/helpers/FrmStylesHelper.php +4 -4
  17. classes/helpers/FrmTipsHelper.php +1 -1
  18. classes/models/FrmEntry.php +6 -6
  19. classes/models/FrmEntryMeta.php +4 -4
  20. classes/models/FrmField.php +4 -4
  21. classes/models/FrmForm.php +3 -3
  22. classes/models/FrmFormAction.php +2 -0
  23. classes/models/FrmFormMigrator.php +1 -1
  24. classes/models/FrmStyle.php +5 -2
  25. classes/models/FrmUsage.php +7 -3
  26. classes/models/fields/FrmFieldCaptcha.php +1 -1
  27. classes/models/fields/FrmFieldType.php +4 -6
  28. classes/views/addons/upgrade_to_pro.php +6 -2
  29. classes/views/frm-entries/_sidebar-shared-pub.php +2 -2
  30. classes/views/frm-entries/list.php +2 -2
  31. classes/views/frm-entries/no_entries.php +7 -3
  32. classes/views/frm-entries/show.php +3 -0
  33. classes/views/frm-entries/sidebar-shared.php +12 -10
  34. classes/views/frm-fields/back-end/bulk-options-overlay.php +1 -1
  35. classes/views/frm-fields/back-end/field-user-id.php +1 -1
  36. classes/views/frm-fields/back-end/html-content.php +9 -1
  37. classes/views/frm-fields/back-end/inline-modal.php +1 -1
  38. classes/views/frm-fields/back-end/settings.php +50 -25
  39. classes/views/frm-fields/back-end/value-format.php +9 -1
  40. classes/views/frm-fields/single-option.php +4 -5
  41. classes/views/frm-form-actions/_action_icon.php +8 -12
  42. classes/views/frm-form-actions/_action_inside.php +1 -1
  43. classes/views/frm-form-actions/form_action.php +10 -3
  44. classes/views/frm-form-actions/settings.php +14 -5
  45. classes/views/frm-forms/_publish_box.php +1 -1
  46. classes/views/frm-forms/add_field.php +12 -6
  47. classes/views/frm-forms/add_field_links.php +5 -6
  48. classes/views/frm-forms/form.php +5 -3
  49. classes/views/frm-forms/settings-advanced.php +9 -9
  50. classes/views/frm-settings/form.php +17 -27
  51. classes/views/frm-settings/general.php +1 -1
  52. classes/views/frm-settings/settings_cta.php +6 -3
  53. classes/views/frm-settings/tabs.php +1 -1
  54. classes/views/shared/admin-header.php +2 -2
  55. classes/views/shared/confirm-overlay.php +1 -1
  56. classes/views/shared/errors.php +1 -1
  57. classes/views/shared/form-nav.php +1 -3
  58. classes/views/shared/mb_adv_info.php +9 -7
  59. classes/views/shared/upgrade_overlay.php +2 -2
  60. classes/views/styles/header-buttons.php +1 -1
  61. css/font_icons.css +4 -4
  62. css/formidableforms.css +1 -1
  63. css/frm_admin.css +250 -84
  64. css/frm_fonts.css +3 -3
  65. formidable.php +1 -1
  66. images/icons.svg +1069 -0
  67. js/formidable_admin.js +178 -54
  68. languages/formidable.pot +652 -636
  69. readme.txt +21 -1
classes/controllers/FrmAddonsController.php CHANGED
@@ -22,6 +22,7 @@ class FrmAddonsController {
22
  }
23
 
24
  public static function list_addons() {
 
25
  $installed_addons = apply_filters( 'frm_installed_addons', array() );
26
  $license_type = '';
27
 
@@ -484,6 +485,7 @@ class FrmAddonsController {
484
  }
485
 
486
  public static function upgrade_to_pro() {
 
487
  $pro_pricing = self::prepare_pro_info();
488
 
489
  $link_parts = array(
22
  }
23
 
24
  public static function list_addons() {
25
+ FrmAppHelper::include_svg();
26
  $installed_addons = apply_filters( 'frm_installed_addons', array() );
27
  $license_type = '';
28
 
485
  }
486
 
487
  public static function upgrade_to_pro() {
488
+ FrmAppHelper::include_svg();
489
  $pro_pricing = self::prepare_pro_info();
490
 
491
  $link_parts = array(
classes/controllers/FrmAppController.php CHANGED
@@ -39,7 +39,10 @@ class FrmAppController {
39
  $classes .= ' frm-white-body ';
40
  $classes .= self::get_os();
41
 
42
- $page = FrmAppHelper::simple_get( 'frm_action', 'sanitize_title' );
 
 
 
43
  if ( ! empty( $page ) ) {
44
  $classes .= ' frm-admin-page-' . $page;
45
  }
@@ -396,26 +399,6 @@ class FrmAppController {
396
  return $needs_upgrade;
397
  }
398
 
399
- /**
400
- * Remove the admin toolbar on full screen pages.
401
- *
402
- * @since 4.0.01
403
- */
404
- public static function no_admin_bar() {
405
- if ( FrmAppHelper::is_full_screen() ) {
406
- add_filter( 'wp_admin_bar_class', 'FrmAppController::fake_admin_bar_class' );
407
- }
408
- }
409
-
410
- /*
411
- * A class that doesn't exist will hide the admin bar.
412
- *
413
- * @since 4.0.01
414
- */
415
- public static function fake_admin_bar_class() {
416
- return 'Nope';
417
- }
418
-
419
  /**
420
  * Check for database update and trigger js loading
421
  *
39
  $classes .= ' frm-white-body ';
40
  $classes .= self::get_os();
41
 
42
+ $page = str_replace( 'formidable-', '', FrmAppHelper::simple_get( 'page', 'sanitize_title' ) );
43
+ if ( empty( $page ) ) {
44
+ $page = FrmAppHelper::simple_get( 'frm_action', 'sanitize_title' );
45
+ }
46
  if ( ! empty( $page ) ) {
47
  $classes .= ' frm-admin-page-' . $page;
48
  }
399
  return $needs_upgrade;
400
  }
401
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
402
  /**
403
  * Check for database update and trigger js loading
404
  *
classes/controllers/FrmEntriesController.php CHANGED
@@ -29,6 +29,7 @@ class FrmEntriesController {
29
  /* Display in Back End */
30
  public static function route() {
31
  $action = FrmAppHelper::get_param( 'frm_action', '', 'get', 'sanitize_title' );
 
32
 
33
  switch ( $action ) {
34
  case 'show':
@@ -552,7 +553,7 @@ class FrmEntriesController {
552
  }
553
 
554
  if ( $errors == '' && ! $ajax ) {
555
- $errors = FrmEntryValidate::validate( $_POST );
556
  }
557
 
558
  /**
29
  /* Display in Back End */
30
  public static function route() {
31
  $action = FrmAppHelper::get_param( 'frm_action', '', 'get', 'sanitize_title' );
32
+ FrmAppHelper::include_svg();
33
 
34
  switch ( $action ) {
35
  case 'show':
553
  }
554
 
555
  if ( $errors == '' && ! $ajax ) {
556
+ $errors = FrmEntryValidate::validate( wp_unslash( $_POST ) );
557
  }
558
 
559
  /**
classes/controllers/FrmFormActionsController.php CHANGED
@@ -222,6 +222,14 @@ class FrmFormActionsController {
222
  }
223
  }
224
 
 
 
 
 
 
 
 
 
225
  include( FrmAppHelper::plugin_path() . '/classes/views/frm-form-actions/_action_icon.php' );
226
  }
227
 
222
  }
223
  }
224
 
225
+ // HTML to include on the icon.
226
+ $icon_atts = array();
227
+ if ( $action_control->action_options['color'] !== 'var(--primary-hover)' ) {
228
+ $icon_atts = array(
229
+ 'style' => '--primary-hover:' . $action_control->action_options['color'],
230
+ );
231
+ }
232
+
233
  include( FrmAppHelper::plugin_path() . '/classes/views/frm-form-actions/_action_icon.php' );
234
  }
235
 
classes/controllers/FrmFormsController.php CHANGED
@@ -865,6 +865,7 @@ class FrmFormsController {
865
  }
866
 
867
  $all_templates = FrmForm::getAll( array( 'is_template' => 1 ), 'name' );
 
868
 
869
  if ( defined( 'DOING_AJAX' ) ) {
870
  wp_die();
@@ -1278,10 +1279,12 @@ class FrmFormsController {
1278
  public static function route() {
1279
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
1280
  $vars = array();
 
 
1281
  if ( isset( $_POST['frm_compact_fields'] ) ) {
1282
  FrmAppHelper::permission_check( 'frm_edit_forms' );
1283
 
1284
- $json_vars = htmlspecialchars_decode( nl2br( wp_unslash( str_replace( '"', '\\\"', $_POST['frm_compact_fields'] ) ) ) );
1285
  $json_vars = json_decode( $json_vars, true );
1286
  if ( empty( $json_vars ) ) {
1287
  // json decoding failed so we should return an error message.
@@ -1433,12 +1436,7 @@ class FrmFormsController {
1433
  global $frm_vars;
1434
  if ( isset( $frm_vars['skip_shortcode'] ) && $frm_vars['skip_shortcode'] ) {
1435
  $sc = '[formidable';
1436
- if ( ! empty( $atts ) ) {
1437
- foreach ( $atts as $k => $v ) {
1438
- $sc .= ' ' . $k . '="' . esc_attr( $v ) . '"';
1439
- }
1440
- }
1441
-
1442
  return $sc . ']';
1443
  }
1444
 
865
  }
866
 
867
  $all_templates = FrmForm::getAll( array( 'is_template' => 1 ), 'name' );
868
+ $has_fields = isset( $values['fields'] ) && ! empty( $values['fields'] );
869
 
870
  if ( defined( 'DOING_AJAX' ) ) {
871
  wp_die();
1279
  public static function route() {
1280
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
1281
  $vars = array();
1282
+ FrmAppHelper::include_svg();
1283
+
1284
  if ( isset( $_POST['frm_compact_fields'] ) ) {
1285
  FrmAppHelper::permission_check( 'frm_edit_forms' );
1286
 
1287
+ $json_vars = htmlspecialchars_decode( nl2br( str_replace( '"', '"', wp_unslash( $_POST['frm_compact_fields'] ) ) ) );
1288
  $json_vars = json_decode( $json_vars, true );
1289
  if ( empty( $json_vars ) ) {
1290
  // json decoding failed so we should return an error message.
1436
  global $frm_vars;
1437
  if ( isset( $frm_vars['skip_shortcode'] ) && $frm_vars['skip_shortcode'] ) {
1438
  $sc = '[formidable';
1439
+ $sc .= FrmAppHelper::array_to_html_params( $atts );
 
 
 
 
 
1440
  return $sc . ']';
1441
  }
1442
 
classes/controllers/FrmHooksController.php CHANGED
@@ -88,7 +88,6 @@ class FrmHooksController {
88
  add_filter( 'admin_body_class', 'FrmAppController::add_admin_class', 999 );
89
  add_action( 'admin_enqueue_scripts', 'FrmAppController::load_wp_admin_style' );
90
  add_action( 'admin_notices', 'FrmAppController::pro_get_started_headline' );
91
- add_action( 'admin_init', 'FrmAppController::no_admin_bar', 0 );
92
  add_action( 'admin_init', 'FrmAppController::admin_init', 11 );
93
  add_filter( 'plugin_action_links_' . FrmAppHelper::plugin_folder() . '/formidable.php', 'FrmAppController::settings_link' );
94
  add_filter( 'admin_footer_text', 'FrmAppController::set_footer_text' );
88
  add_filter( 'admin_body_class', 'FrmAppController::add_admin_class', 999 );
89
  add_action( 'admin_enqueue_scripts', 'FrmAppController::load_wp_admin_style' );
90
  add_action( 'admin_notices', 'FrmAppController::pro_get_started_headline' );
 
91
  add_action( 'admin_init', 'FrmAppController::admin_init', 11 );
92
  add_filter( 'plugin_action_links_' . FrmAppHelper::plugin_folder() . '/formidable.php', 'FrmAppController::settings_link' );
93
  add_filter( 'admin_footer_text', 'FrmAppController::set_footer_text' );
classes/controllers/FrmSettingsController.php CHANGED
@@ -23,6 +23,7 @@ class FrmSettingsController {
23
  $target_path = $uploads['basedir'] . '/formidable/css';
24
 
25
  $sections = self::get_settings_tabs();
 
26
 
27
  require( FrmAppHelper::plugin_path() . '/classes/views/frm-settings/form.php' );
28
  }
@@ -207,7 +208,7 @@ class FrmSettingsController {
207
  if ( ! isset( $frm_vars['settings_routed'] ) || ! $frm_vars['settings_routed'] ) {
208
  $errors = $frm_settings->validate( $_POST, array() );
209
 
210
- $frm_settings->update( stripslashes_deep( $_POST ) );
211
 
212
  if ( empty( $errors ) ) {
213
  $frm_settings->store();
@@ -226,9 +227,21 @@ class FrmSettingsController {
226
  self::display_form( $errors, $message );
227
  }
228
 
 
 
 
 
 
 
 
 
 
 
229
  public static function route( $stop_load = false ) {
230
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
231
  $action = FrmAppHelper::get_param( $action, '', 'get', 'sanitize_title' );
 
 
232
  if ( $action == 'process-form' ) {
233
  self::process_form( $stop_load );
234
  } elseif ( $stop_load != 'stop_load' ) {
23
  $target_path = $uploads['basedir'] . '/formidable/css';
24
 
25
  $sections = self::get_settings_tabs();
26
+ $current = FrmAppHelper::simple_get( 't', 'sanitize_title', 'general_settings' );
27
 
28
  require( FrmAppHelper::plugin_path() . '/classes/views/frm-settings/form.php' );
29
  }
208
  if ( ! isset( $frm_vars['settings_routed'] ) || ! $frm_vars['settings_routed'] ) {
209
  $errors = $frm_settings->validate( $_POST, array() );
210
 
211
+ $frm_settings->update( wp_unslash( $_POST ) );
212
 
213
  if ( empty( $errors ) ) {
214
  $frm_settings->store();
227
  self::display_form( $errors, $message );
228
  }
229
 
230
+ /**
231
+ * Include the Update button on the global settings page.
232
+ *
233
+ * @since 4.0.02
234
+ */
235
+ public static function save_button() {
236
+ echo '<input class="button-primary frm-button-primary" type="submit"
237
+ value="' . esc_attr__( 'Update', 'formidable' ) . '"/>';
238
+ }
239
+
240
  public static function route( $stop_load = false ) {
241
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
242
  $action = FrmAppHelper::get_param( $action, '', 'get', 'sanitize_title' );
243
+ FrmAppHelper::include_svg();
244
+
245
  if ( $action == 'process-form' ) {
246
  self::process_form( $stop_load );
247
  } elseif ( $stop_load != 'stop_load' ) {
classes/controllers/FrmStylesController.php CHANGED
@@ -333,6 +333,7 @@ class FrmStylesController {
333
 
334
  public static function route() {
335
  $action = FrmAppHelper::get_param( 'frm_action', '', 'get', 'sanitize_title' );
 
336
 
337
  switch ( $action ) {
338
  case 'edit':
333
 
334
  public static function route() {
335
  $action = FrmAppHelper::get_param( 'frm_action', '', 'get', 'sanitize_title' );
336
+ FrmAppHelper::include_svg();
337
 
338
  switch ( $action ) {
339
  case 'edit':
classes/controllers/FrmXMLController.php CHANGED
@@ -111,6 +111,8 @@ class FrmXMLController {
111
  public static function route() {
112
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
113
  $action = FrmAppHelper::get_param( $action, '', 'get', 'sanitize_title' );
 
 
114
  if ( 'import_xml' === $action ) {
115
  return self::import_xml();
116
  } elseif ( 'export_xml' === $action ) {
@@ -169,7 +171,7 @@ class FrmXMLController {
169
  return;
170
  }
171
 
172
- $file = isset( $_FILES['frm_import_file']['tmp_name'] ) ? $_FILES['frm_import_file']['tmp_name'] : '';
173
 
174
  if ( ! is_uploaded_file( $file ) ) {
175
  unset( $file );
@@ -190,7 +192,7 @@ class FrmXMLController {
190
  );
191
  $export_format = apply_filters( 'frm_export_formats', $export_format );
192
 
193
- $file_type = strtolower( pathinfo( $_FILES['frm_import_file']['name'], PATHINFO_EXTENSION ) );
194
  if ( 'xml' !== $file_type && isset( $export_format[ $file_type ] ) ) {
195
  // allow other file types to be imported
196
  do_action( 'frm_before_import_' . $file_type );
111
  public static function route() {
112
  $action = isset( $_REQUEST['frm_action'] ) ? 'frm_action' : 'action';
113
  $action = FrmAppHelper::get_param( $action, '', 'get', 'sanitize_title' );
114
+ FrmAppHelper::include_svg();
115
+
116
  if ( 'import_xml' === $action ) {
117
  return self::import_xml();
118
  } elseif ( 'export_xml' === $action ) {
171
  return;
172
  }
173
 
174
+ $file = isset( $_FILES['frm_import_file']['tmp_name'] ) ? wp_unslash( $_FILES['frm_import_file']['tmp_name'] ) : '';
175
 
176
  if ( ! is_uploaded_file( $file ) ) {
177
  unset( $file );
192
  );
193
  $export_format = apply_filters( 'frm_export_formats', $export_format );
194
 
195
+ $file_type = strtolower( pathinfo( wp_unslash( $_FILES['frm_import_file']['name'], PATHINFO_EXTENSION ) ) );
196
  if ( 'xml' !== $file_type && isset( $export_format[ $file_type ] ) ) {
197
  // allow other file types to be imported
198
  do_action( 'frm_before_import_' . $file_type );
classes/helpers/FrmAppHelper.php CHANGED
@@ -6,12 +6,12 @@ if ( ! defined( 'ABSPATH' ) ) {
6
  class FrmAppHelper {
7
  public static $db_version = 97; //version of the database we are moving to
8
  public static $pro_db_version = 37; //deprecated
9
- public static $font_version = 4;
10
 
11
  /**
12
  * @since 2.0
13
  */
14
- public static $plug_version = '4.0.01';
15
 
16
  /**
17
  * @since 1.07.02
@@ -611,6 +611,7 @@ class FrmAppHelper {
611
  'class' => true,
612
  'id' => true,
613
  'icon' => true,
 
614
  ),
615
  'img' => array(
616
  'alt' => true,
@@ -649,11 +650,23 @@ class FrmAppHelper {
649
  ),
650
  'strike' => array(),
651
  'strong' => array(),
 
 
 
 
 
652
  'svg' => array(
 
 
653
  'xmlns' => true,
654
  'viewbox' => true,
655
  'width' => true,
656
  'height' => true,
 
 
 
 
 
657
  ),
658
  'ul' => $allow_class,
659
  );
@@ -699,6 +712,68 @@ class FrmAppHelper {
699
  return $value;
700
  }
701
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
702
  /**
703
  * @since 3.0
704
  */
@@ -717,6 +792,7 @@ class FrmAppHelper {
717
  public static function add_new_item_link( $atts ) {
718
  if ( isset( $atts['new_link'] ) && ! empty( $atts['new_link'] ) ) { ?>
719
  <a href="<?php echo esc_url( $atts['new_link'] ); ?>" class="button button-primary frm-button-primary frm-with-plus">
 
720
  <?php esc_html_e( 'Add New', 'formidable' ); ?>
721
  </a>
722
  <?php
@@ -1993,6 +2069,8 @@ class FrmAppHelper {
1993
  return;
1994
  }
1995
 
 
 
1996
  $is_pro = self::pro_is_installed() && class_exists( 'FrmProDb' );
1997
  if ( ! $is_pro || self::meets_min_pro_version( $min_version ) ) {
1998
  return;
@@ -2023,6 +2101,32 @@ class FrmAppHelper {
2023
  return ! class_exists( 'FrmProDb' ) || version_compare( FrmProDb::$plug_version, $min_version, '>=' );
2024
  }
2025
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2026
  public static function locales( $type = 'date' ) {
2027
  $locales = array(
2028
  'en' => __( 'English', 'formidable' ),
6
  class FrmAppHelper {
7
  public static $db_version = 97; //version of the database we are moving to
8
  public static $pro_db_version = 37; //deprecated
9
+ public static $font_version = 7;
10
 
11
  /**
12
  * @since 2.0
13
  */
14
+ public static $plug_version = '4.0.02';
15
 
16
  /**
17
  * @since 1.07.02
611
  'class' => true,
612
  'id' => true,
613
  'icon' => true,
614
+ 'style' => true,
615
  ),
616
  'img' => array(
617
  'alt' => true,
650
  ),
651
  'strike' => array(),
652
  'strong' => array(),
653
+ 'symbol' => array(
654
+ 'class' => true,
655
+ 'id' => true,
656
+ 'viewbox' => true,
657
+ ),
658
  'svg' => array(
659
+ 'class' => true,
660
+ 'id' => true,
661
  'xmlns' => true,
662
  'viewbox' => true,
663
  'width' => true,
664
  'height' => true,
665
+ 'style' => true,
666
+ ),
667
+ 'use' => array(
668
+ 'href' => true,
669
+ 'xlink:href' => true,
670
  ),
671
  'ul' => $allow_class,
672
  );
712
  return $value;
713
  }
714
 
715
+ /**
716
+ * Try to show the SVG if possible. Otherwise, use the font icon.
717
+ *
718
+ * @since 4.0.02
719
+ * @param string $class
720
+ * @param array $atts
721
+ */
722
+ public static function icon_by_class( $class, $atts = array() ) {
723
+ $echo = ! isset( $atts['echo'] ) || $atts['echo'];
724
+ if ( isset( $atts['echo'] ) ) {
725
+ unset( $atts['echo'] );
726
+ }
727
+
728
+ $html_atts = self::array_to_html_params( $atts );
729
+
730
+ $icon = trim( str_replace( array( 'frm_icon_font', 'frmfont ' ), '', $class ) );
731
+ if ( $icon === $class ) {
732
+ $icon = '<i class="' . esc_attr( $class ) . '"' . $html_atts . '></i>';
733
+ } else {
734
+ $class = strpos( $icon, ' ' ) === false ? '' : ' ' . $icon;
735
+ if ( strpos( $icon, ' ' ) ) {
736
+ $icon = explode( ' ', $icon );
737
+ $icon = reset( $icon );
738
+ }
739
+ $icon = '<svg class="frmsvg' . esc_attr( $class ) . '"' . $html_atts . '>
740
+ <use xlink:href="#' . esc_attr( $icon ) . '" />
741
+ </svg>';
742
+ }
743
+
744
+ if ( $echo ) {
745
+ echo $icon; // WPCS: XSS ok.
746
+ } else {
747
+ return $icon;
748
+ }
749
+ }
750
+
751
+ /**
752
+ * Include svg images.
753
+ *
754
+ * @since 4.0.02
755
+ */
756
+ public static function include_svg() {
757
+ include_once( self::plugin_path() . '/images/icons.svg' );
758
+ }
759
+
760
+ /**
761
+ * Convert an associative array to HTML values.
762
+ *
763
+ * @since 4.0.02
764
+ * @param array $atts
765
+ * @return string
766
+ */
767
+ public static function array_to_html_params( $atts ) {
768
+ $html = '';
769
+ if ( ! empty( $atts ) ) {
770
+ foreach ( $atts as $key => $value ) {
771
+ $html .= ' ' . esc_attr( $key ) . '="' . esc_attr( $value ) . '"';
772
+ }
773
+ }
774
+ return $html;
775
+ }
776
+
777
  /**
778
  * @since 3.0
779
  */
792
  public static function add_new_item_link( $atts ) {
793
  if ( isset( $atts['new_link'] ) && ! empty( $atts['new_link'] ) ) { ?>
794
  <a href="<?php echo esc_url( $atts['new_link'] ); ?>" class="button button-primary frm-button-primary frm-with-plus">
795
+ <?php self::icon_by_class( 'frmfont frm_plus_icon frm_svg15' ); ?>
796
  <?php esc_html_e( 'Add New', 'formidable' ); ?>
797
  </a>
798
  <?php
2069
  return;
2070
  }
2071
 
2072
+ self::php_version_notice();
2073
+
2074
  $is_pro = self::pro_is_installed() && class_exists( 'FrmProDb' );
2075
  if ( ! $is_pro || self::meets_min_pro_version( $min_version ) ) {
2076
  return;
2101
  return ! class_exists( 'FrmProDb' ) || version_compare( FrmProDb::$plug_version, $min_version, '>=' );
2102
  }
2103
 
2104
+ /**
2105
+ * Show a message if the browser or PHP version is below the recommendations.
2106
+ *
2107
+ * @since 4.0.02
2108
+ */
2109
+ private static function php_version_notice() {
2110
+ $message = array();
2111
+ if ( version_compare( phpversion(), '5.6', '<' ) ) {
2112
+ $message[] = __( 'The version of PHP on your server is too low. If this is not corrected, you may see issues with Formidable Forms. Please contact your web host and ask to be updated to PHP 7.0+.', 'formidable' );
2113
+ }
2114
+
2115
+ $browser = self::get_server_value( 'HTTP_USER_AGENT' );
2116
+ $is_ie = strpos( $browser, 'MSIE' ) !== false;
2117
+ if ( $is_ie ) {
2118
+ $message[] = __( 'You are using an outdated browser that is not compatible with Formidable Forms. Please update to a more current browser (we recommend Chrome).', 'formidable' );
2119
+ }
2120
+
2121
+ foreach ( $message as $m ) {
2122
+ ?>
2123
+ <div class="error frm_previous_install">
2124
+ <?php echo esc_html( $m ); ?>
2125
+ </div>
2126
+ <?php
2127
+ }
2128
+ }
2129
+
2130
  public static function locales( $type = 'date' ) {
2131
  $locales = array(
2132
  'en' => __( 'English', 'formidable' ),
classes/helpers/FrmEntriesHelper.php CHANGED
@@ -72,7 +72,7 @@ class FrmEntriesHelper {
72
  $field->default_value = apply_filters( 'frm_get_default_value', $field->default_value, $field, true, $return_array );
73
 
74
  if ( isset( $field->field_options['placeholder'] ) ) {
75
- $field->field_options['placeholder'] = apply_filters( 'frm_filter_default_value', $field->field_options['placeholder'], $field, true, $return_array );
76
  }
77
  }
78
 
@@ -308,11 +308,11 @@ class FrmEntriesHelper {
308
  $field_id = is_object( $field ) ? $field->id : $field;
309
 
310
  if ( empty( $args['parent_field_id'] ) ) {
311
- $value = isset( $_POST['item_meta'][ $field_id ] ) ? $_POST['item_meta'][ $field_id ] : '';
312
  } else {
313
- $value = isset( $_POST['item_meta'][ $args['parent_field_id'] ][ $args['key_pointer'] ][ $field_id ] ) ? $_POST['item_meta'][ $args['parent_field_id'] ][ $args['key_pointer'] ][ $field_id ] : '';
314
  }
315
- $value = wp_unslash( $value );
316
  FrmAppHelper::sanitize_value( 'wp_kses_post', $value );
317
  }
318
 
@@ -553,7 +553,7 @@ class FrmEntriesHelper {
553
  }
554
  ?>
555
  >
556
- <i class="<?php echo esc_attr( $link['icon'] ); ?>" aria-hidden="true"></i>
557
  <span class="frm_link_label"><?php echo esc_html( $link['label'] ); ?></span>
558
  </a>
559
  </div>
72
  $field->default_value = apply_filters( 'frm_get_default_value', $field->default_value, $field, true, $return_array );
73
 
74
  if ( isset( $field->field_options['placeholder'] ) ) {
75
+ $field->field_options['placeholder'] = apply_filters( 'frm_get_default_value', $field->field_options['placeholder'], $field, false, false );
76
  }
77
  }
78
 
308
  $field_id = is_object( $field ) ? $field->id : $field;
309
 
310
  if ( empty( $args['parent_field_id'] ) ) {
311
+ $value = isset( $_POST['item_meta'][ $field_id ] ) ? wp_unslash( $_POST['item_meta'][ $field_id ] ) : '';
312
  } else {
313
+ $value = isset( $_POST['item_meta'][ $args['parent_field_id'] ][ $args['key_pointer'] ][ $field_id ] ) ? wp_unslash( $_POST['item_meta'][ $args['parent_field_id'] ][ $args['key_pointer'] ][ $field_id ] ) : '';
314
  }
315
+
316
  FrmAppHelper::sanitize_value( 'wp_kses_post', $value );
317
  }
318
 
553
  }
554
  ?>
555
  >
556
+ <?php FrmAppHelper::icon_by_class( $link['icon'], array( 'aria-hidden' => 'true' ) ); ?>
557
  <span class="frm_link_label"><?php echo esc_html( $link['label'] ); ?></span>
558
  </a>
559
  </div>
classes/helpers/FrmEntriesListHelper.php CHANGED
@@ -98,6 +98,13 @@ class FrmEntriesListHelper extends FrmListHelper {
98
  if ( $form_id ) {
99
  $form = FrmForm::getOne( $form_id );
100
  }
 
 
 
 
 
 
 
101
  $colspan = $this->get_column_count();
102
 
103
  include( FrmAppHelper::plugin_path() . '/classes/views/frm-entries/no_entries.php' );
98
  if ( $form_id ) {
99
  $form = FrmForm::getOne( $form_id );
100
  }
101
+ $has_form = ! empty( $form );
102
+
103
+ if ( ! $has_form ) {
104
+ $has_form = FrmForm::getAll( array(), '', 1 );
105
+ $has_form = ! empty( $has_form );
106
+ }
107
+
108
  $colspan = $this->get_column_count();
109
 
110
  include( FrmAppHelper::plugin_path() . '/classes/views/frm-entries/no_entries.php' );
classes/helpers/FrmFieldsHelper.php CHANGED
@@ -180,12 +180,16 @@ class FrmFieldsHelper {
180
  * @param mixed $value
181
  */
182
  private static function get_posted_field_setting( $setting, &$value ) {
183
- if ( isset( $_POST['field_options'][ $setting ] ) ) {
184
- $value = maybe_unserialize( $_POST['field_options'][ $setting ] );
185
- if ( strpos( $setting, 'html' ) !== false ) {
186
- // strip slashes from HTML but not regex
187
- $value = stripslashes_deep( $value );
188
- }
 
 
 
 
189
  }
190
  }
191
 
@@ -1048,9 +1052,9 @@ class FrmFieldsHelper {
1048
  // For fields inside repeating sections - note, don't check if $pointer is true because it will often be zero
1049
  if ( $parent && isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] ) ) {
1050
  if ( FrmField::is_field_with_multiple_values( $field ) ) {
1051
- $other_val = isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ][ $opt_key ] ) ? sanitize_text_field( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ][ $opt_key ] ) : '';
1052
  } else {
1053
- $other_val = sanitize_text_field( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] );
1054
  }
1055
 
1056
  return $other_val;
@@ -1059,9 +1063,9 @@ class FrmFieldsHelper {
1059
  // For normal fields
1060
 
1061
  if ( FrmField::is_field_with_multiple_values( $field ) ) {
1062
- $other_val = isset( $_POST['item_meta']['other'][ $field['id'] ][ $opt_key ] ) ? sanitize_text_field( $_POST['item_meta']['other'][ $field['id'] ][ $opt_key ] ) : '';
1063
  } else {
1064
- $other_val = sanitize_text_field( $_POST['item_meta']['other'][ $field['id'] ] );
1065
  }
1066
 
1067
  return $other_val;
180
  * @param mixed $value
181
  */
182
  private static function get_posted_field_setting( $setting, &$value ) {
183
+ if ( ! isset( $_POST['field_options'][ $setting ] ) ) {
184
+ return;
185
+ }
186
+
187
+ if ( strpos( $setting, 'html' ) !== false ) {
188
+ // Strip slashes from HTML but not regex.
189
+ $value = maybe_unserialize( wp_unslash( $_POST['field_options'][ $setting ] ) );
190
+ } else {
191
+ // TODO: Remove stripslashes on output, and use on input only.
192
+ $value = maybe_unserialize( $_POST['field_options'][ $setting ] ); // WPCS: sanitization ok.
193
  }
194
  }
195
 
1052
  // For fields inside repeating sections - note, don't check if $pointer is true because it will often be zero
1053
  if ( $parent && isset( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] ) ) {
1054
  if ( FrmField::is_field_with_multiple_values( $field ) ) {
1055
+ $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 ] ) ) : '';
1056
  } else {
1057
+ $other_val = sanitize_text_field( wp_unslash( $_POST['item_meta'][ $parent ][ $pointer ]['other'][ $field['id'] ] ) );
1058
  }
1059
 
1060
  return $other_val;
1063
  // For normal fields
1064
 
1065
  if ( FrmField::is_field_with_multiple_values( $field ) ) {
1066
+ $other_val = isset( $_POST['item_meta']['other'][ $field['id'] ][ $opt_key ] ) ? sanitize_text_field( wp_unslash( $_POST['item_meta']['other'][ $field['id'] ][ $opt_key ] ) ) : '';
1067
  } else {
1068
+ $other_val = sanitize_text_field( wp_unslash( $_POST['item_meta']['other'][ $field['id'] ] ) );
1069
  }
1070
 
1071
  return $other_val;
classes/helpers/FrmFormsHelper.php CHANGED
@@ -108,7 +108,7 @@ class FrmFormsHelper {
108
  <a href="#" id="frm-navbarDrop" class="frm-dropdown-toggle" data-toggle="dropdown">
109
  <h1 title="<?php echo esc_attr( $truncated_name === $name ? '' : $name ); ?>">
110
  <?php echo esc_html( $truncated_name ); ?>
111
- <b class="frm_icon_font frm_arrowdown4_icon"></b>
112
  </h1>
113
  </a>
114
  <ul class="frm-dropdown-menu frm-on-top frm-inline-modal frm_code_list frm-full-hover" role="menu" aria-labelledby="frm-navbarDrop">
@@ -273,7 +273,7 @@ class FrmFormsHelper {
273
  */
274
  public static function setup_edit_vars( $values, $record, $post_values = array() ) {
275
  if ( empty( $post_values ) ) {
276
- $post_values = stripslashes_deep( $_POST );
277
  }
278
 
279
  $values['form_key'] = isset( $post_values['form_key'] ) ? $post_values['form_key'] : $record->form_key;
@@ -518,14 +518,14 @@ BEFORE_HTML;
518
  <a href="javascript:void(0)" class="frmids frm_insert_code"
519
  data-code="<?php echo esc_attr( $args['id'] ); ?>">
520
  <span>[<?php echo esc_attr( isset( $args['id_label'] ) ? $args['id_label'] : $args['id'] ); ?>]</span>
521
- <i class="<?php echo esc_attr( $field['icon'] ); ?>" aria-hidden="true"></i>
522
  <?php echo esc_attr( FrmAppHelper::truncate( $args['name'], 60 ) ); ?>
523
  </a>
524
  <a href="javascript:void(0)" class="frmkeys frm_insert_code frm_hidden"
525
  data-code="<?php echo esc_attr( $args['key'] ); ?>">
526
  <span>[<?php echo esc_attr( FrmAppHelper::truncate( isset( $args['key_label'] ) ? $args['key_label'] : $args['key'], 7 ) ); ?>]</span>
527
  <?php if ( isset( $field['icon'] ) ) { ?>
528
- <i class="<?php echo esc_attr( $field['icon'] ); ?>" aria-hidden="true"></i>
529
  <?php } ?>
530
  <?php echo esc_attr( FrmAppHelper::truncate( $args['name'], 60 ) ); ?>
531
  </a>
108
  <a href="#" id="frm-navbarDrop" class="frm-dropdown-toggle" data-toggle="dropdown">
109
  <h1 title="<?php echo esc_attr( $truncated_name === $name ? '' : $name ); ?>">
110
  <?php echo esc_html( $truncated_name ); ?>
111
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_arrowdown4_icon', array( 'aria-hidden' => 'true' ) ); ?>
112
  </h1>
113
  </a>
114
  <ul class="frm-dropdown-menu frm-on-top frm-inline-modal frm_code_list frm-full-hover" role="menu" aria-labelledby="frm-navbarDrop">
273
  */
274
  public static function setup_edit_vars( $values, $record, $post_values = array() ) {
275
  if ( empty( $post_values ) ) {
276
+ $post_values = wp_unslash( $_POST );
277
  }
278
 
279
  $values['form_key'] = isset( $post_values['form_key'] ) ? $post_values['form_key'] : $record->form_key;
518
  <a href="javascript:void(0)" class="frmids frm_insert_code"
519
  data-code="<?php echo esc_attr( $args['id'] ); ?>">
520
  <span>[<?php echo esc_attr( isset( $args['id_label'] ) ? $args['id_label'] : $args['id'] ); ?>]</span>
521
+ <?php FrmAppHelper::icon_by_class( $field['icon'], array( 'aria-hidden' => 'true' ) ); ?>
522
  <?php echo esc_attr( FrmAppHelper::truncate( $args['name'], 60 ) ); ?>
523
  </a>
524
  <a href="javascript:void(0)" class="frmkeys frm_insert_code frm_hidden"
525
  data-code="<?php echo esc_attr( $args['key'] ); ?>">
526
  <span>[<?php echo esc_attr( FrmAppHelper::truncate( isset( $args['key_label'] ) ? $args['key_label'] : $args['key'], 7 ) ); ?>]</span>
527
  <?php if ( isset( $field['icon'] ) ) { ?>
528
+ <?php FrmAppHelper::icon_by_class( $field['icon'], array( 'aria-hidden' => 'true' ) ); ?>
529
  <?php } ?>
530
  <?php echo esc_attr( FrmAppHelper::truncate( $args['name'], 60 ) ); ?>
531
  </a>
classes/helpers/FrmFormsListHelper.php CHANGED
@@ -256,7 +256,13 @@ class FrmFormsListHelper extends FrmListHelper {
256
  break;
257
  case 'entries':
258
  if ( isset( $item->options['no_save'] ) && $item->options['no_save'] ) {
259
- $val = '<i class="frm_icon_font frm_forbid_icon frm_bstooltip" title="' . esc_attr( 'Saving entries is disabled for this form', 'formidable' ) . '"></i>';
 
 
 
 
 
 
260
  } else {
261
  $text = FrmEntry::getRecordCount( $item->id );
262
  $val = current_user_can( 'frm_view_entries' ) ? '<a href="' . esc_url( admin_url( 'admin.php?page=formidable-entries&form=' . $item->id ) ) . '">' . $text . '</a>' : $text;
256
  break;
257
  case 'entries':
258
  if ( isset( $item->options['no_save'] ) && $item->options['no_save'] ) {
259
+ $val = FrmAppHelper::icon_by_class(
260
+ 'frmfont frm_forbid_icon frm_bstooltip',
261
+ array(
262
+ 'title' => __( 'Saving entries is disabled for this form', 'formidable' ),
263
+ 'echo' => false,
264
+ )
265
+ );
266
  } else {
267
  $text = FrmEntry::getRecordCount( $item->id );
268
  $val = current_user_can( 'frm_view_entries' ) ? '<a href="' . esc_url( admin_url( 'admin.php?page=formidable-entries&form=' . $item->id ) ) . '">' . $text . '</a>' : $text;
classes/helpers/FrmStylesHelper.php CHANGED
@@ -228,8 +228,8 @@ class FrmStylesHelper {
228
 
229
  <div class="btn-group hide-if-no-js" id="frm_<?php echo esc_attr( $name ); ?>_select">
230
  <button class="multiselect dropdown-toggle btn btn-default" data-toggle="dropdown" type="button">
231
- <i class="frm_icon_font <?php echo esc_attr( self::icon_key_to_class( $style->post_content[ $name ], '+', $type ) ); ?>"></i>
232
- <i class="frm_icon_font <?php echo esc_attr( self::icon_key_to_class( $style->post_content[ $name ], '-', $type ) ); ?>"></i>
233
  <b class="caret"></b>
234
  </button>
235
  <ul class="multiselect-container frm-dropdown-menu">
@@ -239,8 +239,8 @@ class FrmStylesHelper {
239
  <label>
240
  <input type="radio" value="<?php echo esc_attr( $key ); ?>"/>
241
  <span>
242
- <i class="frm_icon_font <?php echo esc_attr( self::icon_key_to_class( $key, '+', $type ) ); ?>"></i>
243
- <i class="frm_icon_font <?php echo esc_attr( self::icon_key_to_class( $key, '-', $type ) ); ?>"></i>
244
  </span>
245
  </label>
246
  </a>
228
 
229
  <div class="btn-group hide-if-no-js" id="frm_<?php echo esc_attr( $name ); ?>_select">
230
  <button class="multiselect dropdown-toggle btn btn-default" data-toggle="dropdown" type="button">
231
+ <?php FrmAppHelper::icon_by_class( 'frmfont ' . self::icon_key_to_class( $style->post_content[ $name ], '+', $type ) ); ?>
232
+ <?php FrmAppHelper::icon_by_class( 'frmfont ' . self::icon_key_to_class( $style->post_content[ $name ], '-', $type ) ); ?>
233
  <b class="caret"></b>
234
  </button>
235
  <ul class="multiselect-container frm-dropdown-menu">
239
  <label>
240
  <input type="radio" value="<?php echo esc_attr( $key ); ?>"/>
241
  <span>
242
+ <?php FrmAppHelper::icon_by_class( 'frmfont ' . self::icon_key_to_class( $key, '+', $type ) ); ?>
243
+ <?php FrmAppHelper::icon_by_class( 'frmfont ' . self::icon_key_to_class( $key, '-', $type ) ); ?>
244
  </span>
245
  </label>
246
  </a>
classes/helpers/FrmTipsHelper.php CHANGED
@@ -24,7 +24,7 @@ class FrmTipsHelper {
24
  $link = FrmAppHelper::make_affiliate_url( FrmAppHelper::admin_upgrade_link( $tip['link'], $tip['page'] ) );
25
  ?>
26
  <a href="<?php echo esc_url( $link ); ?>" target="_blank" class="frm_pro_tip">
27
- <i class="frm_icon_font frm_star_full_icon"></i>
28
  <span class="pro-tip">
29
  <?php esc_html_e( 'Pro Tip:', 'formidable' ); ?>
30
  </span>
24
  $link = FrmAppHelper::make_affiliate_url( FrmAppHelper::admin_upgrade_link( $tip['link'], $tip['page'] ) );
25
  ?>
26
  <a href="<?php echo esc_url( $link ); ?>" target="_blank" class="frm_pro_tip">
27
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_star_full_icon', array( 'aria-hidden' => 'true' ) ); ?>
28
  <span class="pro-tip">
29
  <?php esc_html_e( 'Pro Tip:', 'formidable' ); ?>
30
  </span>
classes/models/FrmEntry.php CHANGED
@@ -310,18 +310,18 @@ class FrmEntry {
310
  if ( ! $meta ) {
311
  $entry = FrmDb::check_cache( $id . '_nometa', 'frm_entry', $query, 'get_row' );
312
 
313
- return stripslashes_deep( $entry );
314
  }
315
 
316
  $entry = FrmDb::check_cache( $id, 'frm_entry' );
317
  if ( $entry !== false ) {
318
- return stripslashes_deep( $entry );
319
  }
320
 
321
  $entry = $wpdb->get_row( $query ); // WPCS: unprepared SQL ok.
322
  $entry = self::get_meta( $entry );
323
 
324
- return stripslashes_deep( $entry );
325
  }
326
 
327
  public static function get_meta( $entry ) {
@@ -423,7 +423,7 @@ class FrmEntry {
423
  }
424
 
425
  if ( ! $meta || ! $entries ) {
426
- return stripslashes_deep( $entries );
427
  }
428
  unset( $meta );
429
 
@@ -443,7 +443,7 @@ class FrmEntry {
443
  unset( $meta_where );
444
 
445
  if ( ! $metas ) {
446
- return stripslashes_deep( $entries );
447
  }
448
 
449
  foreach ( $metas as $m_key => $meta_val ) {
@@ -467,7 +467,7 @@ class FrmEntry {
467
  }
468
  }
469
 
470
- return stripslashes_deep( $entries );
471
  }
472
 
473
  // Pagination Methods
310
  if ( ! $meta ) {
311
  $entry = FrmDb::check_cache( $id . '_nometa', 'frm_entry', $query, 'get_row' );
312
 
313
+ return wp_unslash( $entry );
314
  }
315
 
316
  $entry = FrmDb::check_cache( $id, 'frm_entry' );
317
  if ( $entry !== false ) {
318
+ return wp_unslash( $entry );
319
  }
320
 
321
  $entry = $wpdb->get_row( $query ); // WPCS: unprepared SQL ok.
322
  $entry = self::get_meta( $entry );
323
 
324
+ return wp_unslash( $entry );
325
  }
326
 
327
  public static function get_meta( $entry ) {
423
  }
424
 
425
  if ( ! $meta || ! $entries ) {
426
+ return wp_unslash( $entries );
427
  }
428
  unset( $meta );
429
 
443
  unset( $meta_where );
444
 
445
  if ( ! $metas ) {
446
+ return wp_unslash( $entries );
447
  }
448
 
449
  foreach ( $metas as $m_key => $meta_val ) {
467
  }
468
  }
469
 
470
+ return wp_unslash( $entries );
471
  }
472
 
473
  // Pagination Methods
classes/models/FrmEntryMeta.php CHANGED
@@ -214,7 +214,7 @@ class FrmEntryMeta {
214
  if ( $cached && isset( $cached->metas ) && isset( $cached->metas[ $field_id ] ) ) {
215
  $result = $cached->metas[ $field_id ];
216
 
217
- return stripslashes_deep( $result );
218
  }
219
 
220
  $get_table = $wpdb->prefix . 'frm_item_metas';
@@ -228,7 +228,7 @@ class FrmEntryMeta {
228
 
229
  $result = FrmDb::get_var( $get_table, $query, 'meta_value' );
230
  $result = maybe_unserialize( $result );
231
- $result = stripslashes_deep( $result );
232
 
233
  return $result;
234
  }
@@ -258,7 +258,7 @@ class FrmEntryMeta {
258
  unset( $k, $v );
259
  }
260
 
261
- return stripslashes_deep( $values );
262
  }
263
 
264
  /**
@@ -310,7 +310,7 @@ class FrmEntryMeta {
310
  }
311
 
312
  foreach ( $results as $k => $result ) {
313
- $results[ $k ]->meta_value = stripslashes_deep( maybe_unserialize( $result->meta_value ) );
314
  unset( $k, $result );
315
  }
316
 
214
  if ( $cached && isset( $cached->metas ) && isset( $cached->metas[ $field_id ] ) ) {
215
  $result = $cached->metas[ $field_id ];
216
 
217
+ return wp_unslash( $result );
218
  }
219
 
220
  $get_table = $wpdb->prefix . 'frm_item_metas';
228
 
229
  $result = FrmDb::get_var( $get_table, $query, 'meta_value' );
230
  $result = maybe_unserialize( $result );
231
+ $result = wp_unslash( $result );
232
 
233
  return $result;
234
  }
258
  unset( $k, $v );
259
  }
260
 
261
+ return wp_unslash( $values );
262
  }
263
 
264
  /**
310
  }
311
 
312
  foreach ( $results as $k => $result ) {
313
+ $results[ $k ]->meta_value = wp_unslash( maybe_unserialize( $result->meta_value ) );
314
  unset( $k, $result );
315
  }
316
 
classes/models/FrmField.php CHANGED
@@ -431,7 +431,7 @@ class FrmField {
431
  self::prepare_options( $results );
432
  self::filter_field( $filter, $results );
433
 
434
- return stripslashes_deep( $results );
435
  }
436
 
437
  /**
@@ -504,7 +504,7 @@ class FrmField {
504
  unset( $result );
505
  }
506
 
507
- return stripslashes_deep( $fields );
508
  }
509
 
510
  self::$use_cache = false;
@@ -613,7 +613,7 @@ class FrmField {
613
  // make sure old cache doesn't get saved as a transient
614
  $results = wp_cache_get( $cache_key, 'frm_field' );
615
  if ( false !== $results ) {
616
- return stripslashes_deep( $results );
617
  }
618
  }
619
 
@@ -662,7 +662,7 @@ class FrmField {
662
 
663
  FrmDb::set_cache( $cache_key, $results, 'frm_field' );
664
 
665
- return stripslashes_deep( $results );
666
  }
667
 
668
  /**
431
  self::prepare_options( $results );
432
  self::filter_field( $filter, $results );
433
 
434
+ return wp_unslash( $results );
435
  }
436
 
437
  /**
504
  unset( $result );
505
  }
506
 
507
+ return wp_unslash( $fields );
508
  }
509
 
510
  self::$use_cache = false;
613
  // make sure old cache doesn't get saved as a transient
614
  $results = wp_cache_get( $cache_key, 'frm_field' );
615
  if ( false !== $results ) {
616
+ return wp_unslash( $results );
617
  }
618
  }
619
 
662
 
663
  FrmDb::set_cache( $cache_key, $results, 'frm_field' );
664
 
665
+ return wp_unslash( $results );
666
  }
667
 
668
  /**
classes/models/FrmForm.php CHANGED
@@ -570,7 +570,7 @@ class FrmForm {
570
  $cache->options = maybe_unserialize( $cache->options );
571
  }
572
 
573
- return stripslashes_deep( $cache );
574
  }
575
  }
576
 
@@ -587,7 +587,7 @@ class FrmForm {
587
  $results->options = maybe_unserialize( $results->options );
588
  }
589
 
590
- return stripslashes_deep( $results );
591
  }
592
 
593
  /**
@@ -621,7 +621,7 @@ class FrmForm {
621
  $results = reset( $results );
622
  }
623
 
624
- return stripslashes_deep( $results );
625
  }
626
 
627
  /**
570
  $cache->options = maybe_unserialize( $cache->options );
571
  }
572
 
573
+ return wp_unslash( $cache );
574
  }
575
  }
576
 
587
  $results->options = maybe_unserialize( $results->options );
588
  }
589
 
590
+ return wp_unslash( $results );
591
  }
592
 
593
  /**
621
  $results = reset( $results );
622
  }
623
 
624
+ return wp_unslash( $results );
625
  }
626
 
627
  /**
classes/models/FrmFormAction.php CHANGED
@@ -309,6 +309,8 @@ class FrmFormAction {
309
  $action[ $ck ] = $this->duplicate_array_walk( $action[ $ck ], $subkey, $cv );
310
  } elseif ( $ck == $subkey && isset( $frm_duplicate_ids[ $cv ] ) ) {
311
  $action[ $ck ] = $frm_duplicate_ids[ $cv ];
 
 
312
  }
313
  }
314
  }
309
  $action[ $ck ] = $this->duplicate_array_walk( $action[ $ck ], $subkey, $cv );
310
  } elseif ( $ck == $subkey && isset( $frm_duplicate_ids[ $cv ] ) ) {
311
  $action[ $ck ] = $frm_duplicate_ids[ $cv ];
312
+ } elseif ( $ck == $subkey ) {
313
+ $action[ $ck ] = FrmFieldsHelper::switch_field_ids( $action[ $ck ] );
314
  }
315
  }
316
  }
classes/models/FrmFormMigrator.php CHANGED
@@ -76,7 +76,7 @@ abstract class FrmFormMigrator {
76
  <div id="frm-importer-process" class="frm_hidden">
77
 
78
  <p class="process-count">
79
- <i class="fa fa-spinner fa-spin" aria-hidden="true"></i>
80
  Importing <span class="form-current">1</span> of <span class="form-total">0</span> forms
81
  from <?php echo esc_html( $this->name ); ?>.
82
  </p>
76
  <div id="frm-importer-process" class="frm_hidden">
77
 
78
  <p class="process-count">
79
+ <span class="frm-wait" aria-hidden="true"></span>
80
  Importing <span class="form-current">1</span> of <span class="form-total">0</span> forms
81
  from <?php echo esc_html( $this->name ); ?>.
82
  </p>
classes/models/FrmStyle.php CHANGED
@@ -50,7 +50,7 @@ class FrmStyle {
50
  $action_ids = array();
51
 
52
  foreach ( $all_instances as $number => $new_instance ) {
53
- $new_instance = stripslashes_deep( (array) $new_instance );
54
  $this->id = $new_instance['ID'];
55
  if ( $id != $this->id || ! $_POST || ! isset( $_POST['frm_style_setting'] ) ) {
56
  $all_instances[ $number ] = $new_instance;
@@ -66,7 +66,10 @@ class FrmStyle {
66
  }
67
 
68
  $new_instance['post_title'] = isset( $_POST['frm_style_setting']['post_title'] ) ? sanitize_text_field( wp_unslash( $_POST['frm_style_setting']['post_title'] ) ) : '';
69
- $new_instance['post_content'] = isset( $_POST['frm_style_setting']['post_content'] ) ? wp_unslash( $_POST['frm_style_setting']['post_content'] ) : '';
 
 
 
70
  $new_instance['post_type'] = FrmStylesController::$post_type;
71
  $new_instance['post_status'] = 'publish';
72
  $new_instance['menu_order'] = isset( $_POST['frm_style_setting']['menu_order'] ) ? absint( $_POST['frm_style_setting']['menu_order'] ) : 0;
50
  $action_ids = array();
51
 
52
  foreach ( $all_instances as $number => $new_instance ) {
53
+ $new_instance = (array) $new_instance;
54
  $this->id = $new_instance['ID'];
55
  if ( $id != $this->id || ! $_POST || ! isset( $_POST['frm_style_setting'] ) ) {
56
  $all_instances[ $number ] = $new_instance;
66
  }
67
 
68
  $new_instance['post_title'] = isset( $_POST['frm_style_setting']['post_title'] ) ? sanitize_text_field( wp_unslash( $_POST['frm_style_setting']['post_title'] ) ) : '';
69
+
70
+ // Don't wp_unslash yet since it removes backslashes.
71
+ $new_instance['post_content'] = isset( $_POST['frm_style_setting']['post_content'] ) ? $_POST['frm_style_setting']['post_content'] : ''; // WPCS: sanitization ok.
72
+ FrmAppHelper::sanitize_value( 'wp_kses_post', $new_instance['post_content'] );
73
  $new_instance['post_type'] = FrmStylesController::$post_type;
74
  $new_instance['post_status'] = 'publish';
75
  $new_instance['menu_order'] = isset( $_POST['frm_style_setting']['menu_order'] ) ? absint( $_POST['frm_style_setting']['menu_order'] ) : 0;
classes/models/FrmUsage.php CHANGED
@@ -76,7 +76,7 @@ class FrmUsage {
76
  'entry_count' => FrmEntry::getRecordCount(),
77
  'timestamp' => gmdate( 'c' ),
78
 
79
- 'theme_name' => $theme_data->Name, // phpcs:ignore WordPress.NamingConventions
80
  'plugins' => $this->plugins(),
81
  'settings' => array(
82
  $this->settings(),
@@ -280,7 +280,7 @@ class FrmUsage {
280
  $field_query = array(
281
  'or' => 1,
282
  'fi.form_id' => $form_id,
283
- 'fi.parent_form_id' => $form_id,
284
  );
285
 
286
  return FrmDb::get_count( $join, $field_query );
@@ -313,7 +313,11 @@ class FrmUsage {
313
  'order_by' => 'id DESC',
314
  );
315
 
316
- return FrmDb::get_results( 'frm_fields', array(), 'form_id, name, type', $args );
 
 
 
 
317
  }
318
 
319
  /**
76
  'entry_count' => FrmEntry::getRecordCount(),
77
  'timestamp' => gmdate( 'c' ),
78
 
79
+ 'theme_name' => is_object( $theme_data ) ? $theme_data->Name : '', // phpcs:ignore WordPress.NamingConventions
80
  'plugins' => $this->plugins(),
81
  'settings' => array(
82
  $this->settings(),
280
  $field_query = array(
281
  'or' => 1,
282
  'fi.form_id' => $form_id,
283
+ 'parent_form_id' => $form_id,
284
  );
285
 
286
  return FrmDb::get_count( $join, $field_query );
313
  'order_by' => 'id DESC',
314
  );
315
 
316
+ $fields = FrmDb::get_results( 'frm_fields', array(), 'form_id, name, type, field_options', $args );
317
+ foreach ( $fields as $k => $field ) {
318
+ $fields[ $k ]->field_options = json_encode( maybe_unserialize( $field->field_options ) );
319
+ }
320
+ return $fields;
321
  }
322
 
323
  /**
classes/models/fields/FrmFieldCaptcha.php CHANGED
@@ -174,7 +174,7 @@ class FrmFieldCaptcha extends FrmFieldType {
174
  }
175
 
176
  protected function should_validate() {
177
- $is_hidden_field = apply_filters( 'frm_is_field_hidden', false, $this->field, stripslashes_deep( $_POST ) ); // WPCS: CSRF ok.
178
  if ( FrmAppHelper::is_admin() || $is_hidden_field ) {
179
  return false;
180
  }
174
  }
175
 
176
  protected function should_validate() {
177
+ $is_hidden_field = apply_filters( 'frm_is_field_hidden', false, $this->field, wp_unslash( $_POST ) ); // WPCS: CSRF ok.
178
  if ( FrmAppHelper::is_admin() || $is_hidden_field ) {
179
  return false;
180
  }
classes/models/fields/FrmFieldType.php CHANGED
@@ -360,7 +360,8 @@ DEFAULT_HTML;
360
  return;
361
  }
362
 
363
- if ( empty( array_filter( $default_value ) ) ) {
 
364
  $default_value = '';
365
  } else {
366
  $default_value = implode( $default_value, ',' );
@@ -814,12 +815,9 @@ DEFAULT_HTML;
814
  $field = isset( $values['field'] ) ? $values['field'] : $this->field;
815
  $input_html = $this->get_field_input_html_hook( $field );
816
  $select_atts = $this->get_select_atributes( $values );
817
- $select = '';
818
- foreach ( $select_atts as $name => $value ) {
819
- $select .= $name . '="' . esc_attr( $value ) . '" ';
820
- }
821
 
822
- return '<select ' . $select . $input_html . '>';
823
  }
824
 
825
  /**
360
  return;
361
  }
362
 
363
+ $is_empty = array_filter( $default_value );
364
+ if ( empty( $is_empty ) ) {
365
  $default_value = '';
366
  } else {
367
  $default_value = implode( $default_value, ',' );
815
  $field = isset( $values['field'] ) ? $values['field'] : $this->field;
816
  $input_html = $this->get_field_input_html_hook( $field );
817
  $select_atts = $this->get_select_atributes( $values );
818
+ $select = FrmAppHelper::array_to_html_params( $select_atts ) . ' ';
 
 
 
819
 
820
+ return '<select' . $select . $input_html . '>';
821
  }
822
 
823
  /**
classes/views/addons/upgrade_to_pro.php CHANGED
@@ -82,8 +82,12 @@
82
  }
83
  ?>
84
  </th>
85
- <td><i class="frm_icon_font <?php echo esc_attr( $feature['lite'] ? 'frm_checkmark_icon' : 'frm_close_icon' ); ?>"></i></td>
86
- <td><i class="frm_icon_font frm_checkmark_icon"></i></td>
 
 
 
 
87
  </tr>
88
  <?php } ?>
89
  <?php } ?>
82
  }
83
  ?>
84
  </th>
85
+ <td class="<?php echo esc_attr( $feature['lite'] ? 'frm-checked' : '' ); ?>">
86
+ <?php FrmAppHelper::icon_by_class( 'frmfont ' . ( $feature['lite'] ? 'frm_checkmark_icon' : 'frm_close_icon' ) ); ?>
87
+ </td>
88
+ <td class="<?php echo esc_attr( 'frm-checked' ); ?>">
89
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_checkmark_icon' ); ?>
90
+ </td>
91
  </tr>
92
  <?php } ?>
93
  <?php } ?>
classes/views/frm-entries/_sidebar-shared-pub.php CHANGED
@@ -4,7 +4,7 @@ if ( ! isset( $entry ) ) {
4
  } ?>
5
 
6
  <div class="misc-pub-section">
7
- <i class="frm_icon_font frm_calendar_icon"></i>
8
  <span id="timestamp">
9
  <?php
10
  $date_format = __( 'M j, Y @ G:i', 'formidable' );
@@ -19,7 +19,7 @@ if ( ! isset( $entry ) ) {
19
 
20
  <?php if ( $entry->updated_at && $entry->updated_at != $entry->created_at ) { ?>
21
  <div class="misc-pub-section">
22
- <i class="frm_icon_font frm_calendar_icon"></i>
23
  <span id="timestamp">
24
  <?php
25
  printf(
4
  } ?>
5
 
6
  <div class="misc-pub-section">
7
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_calendar_icon', array( 'aria-hidden' => 'true' ) ); ?>
8
  <span id="timestamp">
9
  <?php
10
  $date_format = __( 'M j, Y @ G:i', 'formidable' );
19
 
20
  <?php if ( $entry->updated_at && $entry->updated_at != $entry->created_at ) { ?>
21
  <div class="misc-pub-section">
22
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_calendar_icon', array( 'aria-hidden' => 'true' ) ); ?>
23
  <span id="timestamp">
24
  <?php
25
  printf(
classes/views/frm-entries/list.php CHANGED
@@ -30,8 +30,6 @@
30
  <?php } ?>
31
  <?php } ?>
32
 
33
- <?php require( FrmAppHelper::plugin_path() . '/classes/views/shared/errors.php' ); ?>
34
-
35
  <form id="posts-filter" method="get">
36
  <input type="hidden" name="page" value="formidable-entries" />
37
  <input type="hidden" name="form" value="<?php echo esc_attr( $form ? $form->id : '' ); ?>" />
@@ -41,6 +39,8 @@
41
 
42
  <?php FrmTipsHelper::pro_tip( 'get_entries_tip', 'p' ); ?>
43
 
 
 
44
  <?php $wp_list_table->display(); ?>
45
  </form>
46
  </div>
30
  <?php } ?>
31
  <?php } ?>
32
 
 
 
33
  <form id="posts-filter" method="get">
34
  <input type="hidden" name="page" value="formidable-entries" />
35
  <input type="hidden" name="form" value="<?php echo esc_attr( $form ? $form->id : '' ); ?>" />
39
 
40
  <?php FrmTipsHelper::pro_tip( 'get_entries_tip', 'p' ); ?>
41
 
42
+ <div class="clear"></div>
43
+ <?php require( FrmAppHelper::plugin_path() . '/classes/views/shared/errors.php' ); ?>
44
  <?php $wp_list_table->display(); ?>
45
  </form>
46
  </div>
classes/views/frm-entries/no_entries.php CHANGED
@@ -12,11 +12,15 @@
12
  );
13
  ?>
14
  </p>
15
- <?php } elseif ( $form ) { ?>
16
  <div class="frm_no_entries_header">
17
  <?php
18
- /* translators: %s: The form name */
19
- printf( esc_html__( 'No Entries for form: %s', 'formidable' ), esc_html( $form->name ) );
 
 
 
 
20
  ?>
21
  </div>
22
  <p class="frm_no_entries_text">
12
  );
13
  ?>
14
  </p>
15
+ <?php } elseif ( $form || $has_form ) { ?>
16
  <div class="frm_no_entries_header">
17
  <?php
18
+ if ( $form ) {
19
+ /* translators: %s: The form name */
20
+ printf( esc_html__( 'No Entries for form: %s', 'formidable' ), esc_html( $form->name ) );
21
+ } else {
22
+ esc_html_e( 'No Entries found.', 'formidable' );
23
+ }
24
  ?>
25
  </div>
26
  <p class="frm_no_entries_text">
classes/views/frm-entries/show.php CHANGED
@@ -42,6 +42,9 @@
42
  'include_extras' => 'page, section',
43
  'inline_style' => 0,
44
  'class' => 'frm-alt-table',
 
 
 
45
  )
46
  );
47
  ?>
42
  'include_extras' => 'page, section',
43
  'inline_style' => 0,
44
  'class' => 'frm-alt-table',
45
+ 'show_filename' => true,
46
+ 'show_image' => true,
47
+ 'add_link' => true,
48
  )
49
  );
50
  ?>
classes/views/frm-entries/sidebar-shared.php CHANGED
@@ -27,7 +27,7 @@
27
 
28
  <?php if ( $entry->post_id ) { ?>
29
  <div class="misc-pub-section frm_no_print">
30
- <i aria-hidden="true" class="frm_icon_font frm_calendar_icon"></i>
31
  <?php esc_html_e( 'Post', 'formidable' ); ?>:
32
  <b><?php echo esc_html( get_the_title( $entry->post_id ) ); ?></b>
33
  <span>
@@ -42,20 +42,20 @@
42
  <?php } ?>
43
 
44
  <div class="misc-pub-section">
45
- <i class="frm_icon_font frm_fingerprint_icon" aria-hidden="true"></i>
46
  <?php esc_html_e( 'Entry ID', 'formidable' ); ?>:
47
  <b><?php echo absint( $entry->id ); ?></b>
48
  </div>
49
 
50
  <div class="misc-pub-section">
51
- <i class="frm_icon_font frm_keyalt_icon" aria-hidden="true"></i>
52
  <?php esc_html_e( 'Entry Key', 'formidable' ); ?>:
53
  <b><?php echo esc_html( $entry->item_key ); ?></b>
54
  </div>
55
 
56
  <?php if ( $entry->parent_item_id ) { ?>
57
  <div class="misc-pub-section">
58
- <i class="frm_icon_font frm_sitemap_icon" aria-hidden="true"></i>
59
  <?php esc_html_e( 'Parent Entry ID', 'formidable' ); ?>:
60
  <b><?php echo esc_html( $entry->parent_item_id ); ?></b>
61
  </div>
@@ -68,8 +68,9 @@
68
  <div class="inside">
69
  <?php if ( $entry->user_id ) { ?>
70
  <div class="misc-pub-section">
71
- <i class="frm_icon_font frm_user_icon" aria-hidden="true"></i>
72
  <?php
 
 
73
  printf(
74
  /* translators: %1$s: User display name. */
75
  esc_html__( 'Created by: %1$s', 'formidable' ),
@@ -81,8 +82,9 @@
81
 
82
  <?php if ( $entry->updated_by && $entry->updated_by != $entry->user_id ) { ?>
83
  <div class="misc-pub-section">
84
- <i class="frm_icon_font frm_user_icon" aria-hidden="true"></i>
85
  <?php
 
 
86
  printf(
87
  /* translators: %1$s: User display name. */
88
  esc_html__( 'Updated by: %1$s', 'formidable' ),
@@ -94,7 +96,7 @@
94
 
95
  <?php if ( ! empty( $entry->ip ) ) { ?>
96
  <div class="misc-pub-section">
97
- <i class="frm_icon_font frm_location_icon" aria-hidden="true"></i>
98
  <?php esc_html_e( 'IP Address:', 'formidable' ); ?>
99
  <b><?php echo esc_html( $entry->ip ); ?></b>
100
  </div>
@@ -102,7 +104,7 @@
102
 
103
  <?php if ( isset( $browser ) ) { ?>
104
  <div class="misc-pub-section">
105
- <i class="frm_icon_font frm_browser_icon" aria-hidden="true"></i>
106
  <?php esc_html_e( 'Browser/OS:', 'formidable' ); ?>
107
  <b><?php echo wp_kses_post( $browser ); ?></b>
108
  </div>
@@ -110,7 +112,7 @@
110
 
111
  <?php if ( isset( $data['referrer'] ) ) { ?>
112
  <div class="misc-pub-section frm_force_wrap">
113
- <i class="frm_icon_font frm_history_icon" aria-hidden="true"></i>
114
  <?php esc_html_e( 'Referrer:', 'formidable' ); ?>
115
  <?php echo wp_kses_post( str_replace( "\r\n", '<br/>', $data['referrer'] ) ); ?>
116
  </div>
@@ -123,7 +125,7 @@
123
  }
124
  ?>
125
  <div class="misc-pub-section">
126
- <i class="frm_icon_font frm_attach_file_icon" aria-hidden="true"></i>
127
  <?php echo esc_html( ucfirst( str_replace( '-', ' ', $k ) ) ); ?>:
128
  <b><?php echo wp_kses_post( implode( ', ', (array) $d ) ); ?></b>
129
  </div>
27
 
28
  <?php if ( $entry->post_id ) { ?>
29
  <div class="misc-pub-section frm_no_print">
30
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_calendar_icon', array( 'aria-hidden' => 'true' ) ); ?>
31
  <?php esc_html_e( 'Post', 'formidable' ); ?>:
32
  <b><?php echo esc_html( get_the_title( $entry->post_id ) ); ?></b>
33
  <span>
42
  <?php } ?>
43
 
44
  <div class="misc-pub-section">
45
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_fingerprint_icon', array( 'aria-hidden' => 'true' ) ); ?>
46
  <?php esc_html_e( 'Entry ID', 'formidable' ); ?>:
47
  <b><?php echo absint( $entry->id ); ?></b>
48
  </div>
49
 
50
  <div class="misc-pub-section">
51
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_keyalt_icon', array( 'aria-hidden' => 'true' ) ); ?>
52
  <?php esc_html_e( 'Entry Key', 'formidable' ); ?>:
53
  <b><?php echo esc_html( $entry->item_key ); ?></b>
54
  </div>
55
 
56
  <?php if ( $entry->parent_item_id ) { ?>
57
  <div class="misc-pub-section">
58
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_sitemap_icon', array( 'aria-hidden' => 'true' ) ); ?>
59
  <?php esc_html_e( 'Parent Entry ID', 'formidable' ); ?>:
60
  <b><?php echo esc_html( $entry->parent_item_id ); ?></b>
61
  </div>
68
  <div class="inside">
69
  <?php if ( $entry->user_id ) { ?>
70
  <div class="misc-pub-section">
 
71
  <?php
72
+ FrmAppHelper::icon_by_class( 'frmfont frm_user_icon', array( 'aria-hidden' => 'true' ) );
73
+
74
  printf(
75
  /* translators: %1$s: User display name. */
76
  esc_html__( 'Created by: %1$s', 'formidable' ),
82
 
83
  <?php if ( $entry->updated_by && $entry->updated_by != $entry->user_id ) { ?>
84
  <div class="misc-pub-section">
 
85
  <?php
86
+ FrmAppHelper::icon_by_class( 'frmfont frm_user_icon', array( 'aria-hidden' => 'true' ) );
87
+
88
  printf(
89
  /* translators: %1$s: User display name. */
90
  esc_html__( 'Updated by: %1$s', 'formidable' ),
96
 
97
  <?php if ( ! empty( $entry->ip ) ) { ?>
98
  <div class="misc-pub-section">
99
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_location_icon', array( 'aria-hidden' => 'true' ) ); ?>
100
  <?php esc_html_e( 'IP Address:', 'formidable' ); ?>
101
  <b><?php echo esc_html( $entry->ip ); ?></b>
102
  </div>
104
 
105
  <?php if ( isset( $browser ) ) { ?>
106
  <div class="misc-pub-section">
107
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_browser_icon', array( 'aria-hidden' => 'true' ) ); ?>
108
  <?php esc_html_e( 'Browser/OS:', 'formidable' ); ?>
109
  <b><?php echo wp_kses_post( $browser ); ?></b>
110
  </div>
112
 
113
  <?php if ( isset( $data['referrer'] ) ) { ?>
114
  <div class="misc-pub-section frm_force_wrap">
115
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_history_icon', array( 'aria-hidden' => 'true' ) ); ?>
116
  <?php esc_html_e( 'Referrer:', 'formidable' ); ?>
117
  <?php echo wp_kses_post( str_replace( "\r\n", '<br/>', $data['referrer'] ) ); ?>
118
  </div>
125
  }
126
  ?>
127
  <div class="misc-pub-section">
128
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_attach_file_icon', array( 'aria-hidden' => 'true' ) ); ?>
129
  <?php echo esc_html( ucfirst( str_replace( '-', ' ', $k ) ) ); ?>:
130
  <b><?php echo wp_kses_post( implode( ', ', (array) $d ) ); ?></b>
131
  </div>
classes/views/frm-fields/back-end/bulk-options-overlay.php CHANGED
@@ -1,6 +1,6 @@
1
  <div id="frm-bulk-modal" class="frm_hidden settings-lite-cta">
2
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
3
- <i class="frm_icon_font frm_close_icon" aria-label="<?php esc_attr_e( 'Close', 'formidable' ); ?>" aria-hidden="true"></i>
4
  </a>
5
  <h2>
6
  <?php esc_html_e( 'Bulk Edit Options', 'formidable' ); ?>
1
  <div id="frm-bulk-modal" class="frm_hidden settings-lite-cta">
2
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
3
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_close_icon', array( 'aria-label' => __( 'Close', 'formidable' ) ) ); ?>
4
  </a>
5
  <h2>
6
  <?php esc_html_e( 'Bulk Edit Options', 'formidable' ); ?>
classes/views/frm-fields/back-end/field-user-id.php CHANGED
@@ -1,4 +1,4 @@
1
  <span class="frm-with-left-icon">
2
- <i class="frm_icon_font frm_user_icon"></i>
3
  <input type="text" value="<?php esc_attr_e( 'User ID fields will not show in your form.', 'formidable' ); ?>" disabled />
4
  </span>
1
  <span class="frm-with-left-icon">
2
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_user_icon', array( 'aria-hidden' => 'true' ) ); ?>
3
  <input type="text" value="<?php esc_attr_e( 'User ID fields will not show in your form.', 'formidable' ); ?>" disabled />
4
  </span>
classes/views/frm-fields/back-end/html-content.php CHANGED
@@ -3,7 +3,15 @@
3
  <?php esc_html_e( 'Content', 'formidable' ); ?>
4
  </label>
5
  <span class="frm-with-right-icon">
6
- <i class="frm-show-inline-modal frm_icon_font frm_more_horiz_solid_icon" data-open="frm-smart-values-box" title="<?php esc_attr_e( 'Toggle Options', 'formidable' ); ?>"></i>
 
 
 
 
 
 
 
 
7
  <textarea name="field_options[description_<?php echo absint( $field['id'] ); ?>]" id="frm_description_<?php echo esc_attr( $field['id'] ); ?>" rows="8"><?php
8
  echo FrmAppHelper::esc_textarea( $field['description'] ); // WPCS: XSS ok.
9
  ?></textarea>
3
  <?php esc_html_e( 'Content', 'formidable' ); ?>
4
  </label>
5
  <span class="frm-with-right-icon">
6
+ <?php
7
+ FrmAppHelper::icon_by_class(
8
+ 'frm_icon_font frm_more_horiz_solid_icon frm-show-inline-modal',
9
+ array(
10
+ 'data-open' => 'frm-smart-values-box',
11
+ 'title' => esc_attr__( 'Toggle Options', 'formidable' ),
12
+ )
13
+ );
14
+ ?>
15
  <textarea name="field_options[description_<?php echo absint( $field['id'] ); ?>]" id="frm_description_<?php echo esc_attr( $field['id'] ); ?>" rows="8"><?php
16
  echo FrmAppHelper::esc_textarea( $field['description'] ); // WPCS: XSS ok.
17
  ?></textarea>
classes/views/frm-fields/back-end/inline-modal.php CHANGED
@@ -1,6 +1,6 @@
1
  <div class="frm-inline-modal postbox <?php echo esc_attr( $args['class'] . ( $args['show'] ? '' : ' frm_hidden' ) ); ?>" id="<?php echo esc_attr( $args['id'] ); ?>">
2
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
3
- <i class="frm_icon_font frm_close_icon" aria-label="<?php esc_attr_e( 'Close', 'formidable' ); ?>" aria-hidden="true"></i>
4
  </a>
5
  <ul class="frm-nav-tabs">
6
  <li class="frm-tabs">
1
  <div class="frm-inline-modal postbox <?php echo esc_attr( $args['class'] . ( $args['show'] ? '' : ' frm_hidden' ) ); ?>" id="<?php echo esc_attr( $args['id'] ); ?>">
2
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
3
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_close_icon', array( 'aria-label' => __( 'Close', 'formidable' ) ) ); ?>
4
  </a>
5
  <ul class="frm-nav-tabs">
6
  <li class="frm-tabs">
classes/views/frm-fields/back-end/settings.php CHANGED
@@ -65,6 +65,26 @@
65
  $field_obj->show_primary_options( compact( 'field', 'display', 'values' ) );
66
 
67
  ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  </div>
69
 
70
  <?php if ( ! empty( $display_type ) ) { ?>
@@ -132,20 +152,6 @@ do_action( 'frm_before_field_options', $field );
132
  <i class="frm_icon_font frm_arrowdown6_icon"></i>
133
  </h3>
134
  <div class="frm_grid_container frm-collapse-me">
135
- <?php
136
- if ( $display['description'] ) {
137
- include( FrmAppHelper::plugin_path() . '/classes/views/frm-fields/back-end/field-description.php' );
138
- }
139
- ?>
140
-
141
- <?php if ( $display['clear_on_focus'] ) { ?>
142
- <p>
143
- <label for="frm_placeholder_<?php echo esc_attr( $field['id'] ); ?>">
144
- <?php esc_html_e( 'Placeholder Text', 'formidable' ); ?>
145
- </label>
146
- <input type="text" name="field_options[placeholder_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['placeholder'] ); ?>" id="frm_placeholder_<?php echo esc_attr( $field['id'] ); ?>" data-changeme="field_<?php echo esc_attr( $field['field_key'] ); ?>" data-changeatt="placeholder" />
147
- </p>
148
- <?php } ?>
149
 
150
  <?php if ( $display['default'] ) { ?>
151
  <div class="frm-has-modal">
@@ -160,7 +166,7 @@ do_action( 'frm_before_field_options', $field );
160
  data-frmhide=".frm-inline-modal,.default-value-section-<?php echo esc_attr( $field['id'] ); ?>"
161
  <?php } ?>
162
  >
163
- <i class="<?php echo esc_attr( $link['icon'] ); ?>"></i>
164
  </a>
165
  <?php } ?>
166
  </span>
@@ -171,8 +177,15 @@ do_action( 'frm_before_field_options', $field );
171
  <?php esc_html_e( 'Default Value', 'formidable' ); ?>
172
  </label>
173
  <span class="frm-with-right-icon">
174
- <i class="frm-show-inline-modal frm_icon_font frm_more_horiz_solid_icon" data-open="frm-smart-values-box" title="<?php esc_attr_e( 'Toggle Options', 'formidable' ); ?>"></i>
175
  <?php
 
 
 
 
 
 
 
 
176
  if ( isset( $display['default_value'] ) && $display['default_value'] ) {
177
  $default_name = 'field_options[dyn_default_value_' . $field['id'] . ']';
178
  $default_value = isset( $field['dyn_default_value'] ) ? $field['dyn_default_value'] : '';
@@ -181,8 +194,19 @@ do_action( 'frm_before_field_options', $field );
181
  $default_value = $field['default_value'];
182
  }
183
  $field_obj->default_value_to_string( $default_value );
 
 
 
 
 
 
 
 
 
 
 
 
184
  ?>
185
- <input type="text" name="<?php echo esc_attr( $default_name ); ?>" value="<?php echo esc_attr( $default_value ); ?>" id="frm_default_value_<?php echo esc_attr( $field['id'] ); ?>" class="default-value-field" />
186
  </span>
187
  </p>
188
  <?php do_action( 'frm_default_value_setting', compact( 'field', 'display', 'default_value_types' ) ); ?>
@@ -191,19 +215,20 @@ do_action( 'frm_before_field_options', $field );
191
 
192
  <?php $field_obj->show_after_default( compact( 'field', 'display' ) ); ?>
193
 
194
- <?php if ( $display['css'] ) { ?>
195
- <p class="frm-has-modal">
196
- <label for="frm_classes_<?php echo esc_attr( $field['id'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Add a CSS class to the field container. Use our predefined classes to align multiple fields in single row.', 'formidable' ); ?>">
197
- <?php esc_html_e( 'CSS Layout Classes', 'formidable' ); ?>
198
  </label>
199
- <span class="frm-with-right-icon">
200
- <i class="frm-show-inline-modal frm_icon_font frm_more_horiz_solid_icon" data-open="frm-layout-classes-box" title="<?php esc_attr_e( 'Toggle Options', 'formidable' ); ?>"></i>
201
- <input type="text" name="field_options[classes_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['classes'] ); ?>" class="frm_classes" id="frm_classes_<?php echo esc_attr( $field['id'] ); ?>" data-changeme="frm_field_id_<?php echo esc_attr( $field['id'] ); ?>" data-changeatt="class" />
202
- </span>
203
  </p>
204
  <?php } ?>
205
 
206
  <?php
 
 
 
 
207
  // Field Size
208
  if ( $display['size'] && ! in_array( $field['type'], array( 'select', 'data', 'time' ) ) ) {
209
  $display_max = $display['max'];
65
  $field_obj->show_primary_options( compact( 'field', 'display', 'values' ) );
66
 
67
  ?>
68
+
69
+ <?php if ( $display['css'] ) { ?>
70
+ <p class="frm-has-modal">
71
+ <label for="frm_classes_<?php echo esc_attr( $field['id'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Add a CSS class to the field container. Use our predefined classes to align multiple fields in single row.', 'formidable' ); ?>">
72
+ <?php esc_html_e( 'CSS Layout Classes', 'formidable' ); ?>
73
+ </label>
74
+ <span class="frm-with-right-icon">
75
+ <?php
76
+ FrmAppHelper::icon_by_class(
77
+ 'frm_icon_font frm_more_horiz_solid_icon frm-show-inline-modal',
78
+ array(
79
+ 'data-open' => 'frm-layout-classes-box',
80
+ 'title' => esc_attr__( 'Toggle Options', 'formidable' ),
81
+ )
82
+ );
83
+ ?>
84
+ <input type="text" name="field_options[classes_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['classes'] ); ?>" class="frm_classes" id="frm_classes_<?php echo esc_attr( $field['id'] ); ?>" data-changeme="frm_field_id_<?php echo esc_attr( $field['id'] ); ?>" data-changeatt="class" />
85
+ </span>
86
+ </p>
87
+ <?php } ?>
88
  </div>
89
 
90
  <?php if ( ! empty( $display_type ) ) { ?>
152
  <i class="frm_icon_font frm_arrowdown6_icon"></i>
153
  </h3>
154
  <div class="frm_grid_container frm-collapse-me">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
155
 
156
  <?php if ( $display['default'] ) { ?>
157
  <div class="frm-has-modal">
166
  data-frmhide=".frm-inline-modal,.default-value-section-<?php echo esc_attr( $field['id'] ); ?>"
167
  <?php } ?>
168
  >
169
+ <?php FrmAppHelper::icon_by_class( $link['icon'] ); ?>
170
  </a>
171
  <?php } ?>
172
  </span>
177
  <?php esc_html_e( 'Default Value', 'formidable' ); ?>
178
  </label>
179
  <span class="frm-with-right-icon">
 
180
  <?php
181
+ FrmAppHelper::icon_by_class(
182
+ 'frm_icon_font frm_more_horiz_solid_icon frm-show-inline-modal',
183
+ array(
184
+ 'data-open' => 'frm-smart-values-box',
185
+ 'title' => esc_attr__( 'Toggle Options', 'formidable' ),
186
+ )
187
+ );
188
+
189
  if ( isset( $display['default_value'] ) && $display['default_value'] ) {
190
  $default_name = 'field_options[dyn_default_value_' . $field['id'] . ']';
191
  $default_value = isset( $field['dyn_default_value'] ) ? $field['dyn_default_value'] : '';
194
  $default_value = $field['default_value'];
195
  }
196
  $field_obj->default_value_to_string( $default_value );
197
+
198
+ if ( $display['type'] === 'textarea' || $display['type'] === 'rte' ) {
199
+ ?>
200
+ <textarea name="<?php echo esc_attr( $default_name ); ?>" class="default-value-field" id="frm_default_value_<?php echo esc_attr( $field['id'] ); ?>" rows="3" data-changeme="field_<?php echo esc_attr( $field['field_key'] ); ?>"><?php
201
+ echo FrmAppHelper::esc_textarea( $default_value ); // WPCS: XSS ok.
202
+ ?></textarea>
203
+ <?php
204
+ } else {
205
+ ?>
206
+ <input type="text" name="<?php echo esc_attr( $default_name ); ?>" value="<?php echo esc_attr( $default_value ); ?>" id="frm_default_value_<?php echo esc_attr( $field['id'] ); ?>" class="default-value-field" data-changeme="field_<?php echo esc_attr( $field['field_key'] ); ?>" data-changeatt="value" />
207
+ <?php
208
+ }
209
  ?>
 
210
  </span>
211
  </p>
212
  <?php do_action( 'frm_default_value_setting', compact( 'field', 'display', 'default_value_types' ) ); ?>
215
 
216
  <?php $field_obj->show_after_default( compact( 'field', 'display' ) ); ?>
217
 
218
+ <?php if ( $display['clear_on_focus'] ) { ?>
219
+ <p>
220
+ <label for="frm_placeholder_<?php echo esc_attr( $field['id'] ); ?>">
221
+ <?php esc_html_e( 'Placeholder Text', 'formidable' ); ?>
222
  </label>
223
+ <input type="text" name="field_options[placeholder_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['placeholder'] ); ?>" id="frm_placeholder_<?php echo esc_attr( $field['id'] ); ?>" data-changeme="field_<?php echo esc_attr( $field['field_key'] ); ?>" data-changeatt="placeholder" />
 
 
 
224
  </p>
225
  <?php } ?>
226
 
227
  <?php
228
+ if ( $display['description'] ) {
229
+ include( FrmAppHelper::plugin_path() . '/classes/views/frm-fields/back-end/field-description.php' );
230
+ }
231
+
232
  // Field Size
233
  if ( $display['size'] && ! in_array( $field['type'], array( 'select', 'data', 'time' ) ) ) {
234
  $display_max = $display['max'];
classes/views/frm-fields/back-end/value-format.php CHANGED
@@ -3,7 +3,15 @@
3
  <?php esc_html_e( 'Format', 'formidable' ); ?>
4
  </label>
5
  <span class="frm-with-right-icon">
6
- <i class="frm-show-inline-modal frm_icon_font frm_more_horiz_solid_icon" data-open="frm-input-mask-box" title="<?php esc_attr_e( 'Toggle Options', 'formidable' ); ?>"></i>
 
 
 
 
 
 
 
 
7
  <input type="text" class="frm_long_input frm_format_opt" value="<?php echo esc_attr( $field['format'] ); ?>" name="field_options[format_<?php echo absint( $field['id'] ); ?>]" id="frm_format_<?php echo absint( $field['id'] ); ?>" />
8
  </span>
9
  </p>
3
  <?php esc_html_e( 'Format', 'formidable' ); ?>
4
  </label>
5
  <span class="frm-with-right-icon">
6
+ <?php
7
+ FrmAppHelper::icon_by_class(
8
+ 'frm_icon_font frm_more_horiz_solid_icon frm-show-inline-modal',
9
+ array(
10
+ 'data-open' => 'frm-input-mask-box',
11
+ 'title' => esc_attr__( 'Toggle Options', 'formidable' ),
12
+ )
13
+ );
14
+ ?>
15
  <input type="text" class="frm_long_input frm_format_opt" value="<?php echo esc_attr( $field['format'] ); ?>" name="field_options[format_<?php echo absint( $field['id'] ); ?>]" id="frm_format_<?php echo absint( $field['id'] ); ?>" />
16
  </span>
17
  </p>
classes/views/frm-fields/single-option.php CHANGED
@@ -1,15 +1,14 @@
1
  <li id="frm_delete_field_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>_container" data-optkey="<?php echo esc_attr( $opt_key ); ?>" class="frm_single_option <?php echo $opt_key === '000' ? 'frm_hidden frm_option_template' : ''; ?>">
2
- <i class="frm_icon_font frm_drag_icon frm-drag"></i>
3
-
4
  <input type="<?php echo esc_attr( $default_type ); ?>" name="<?php echo esc_attr( $field_name ); ?>" <?php echo ( isset( $checked ) && $checked ? 'checked="checked"' : '' ); ?> value="<?php echo esc_attr( $field_val ); ?>"/>
5
 
6
- <input type="text" name="field_options[options_<?php echo esc_attr( $field['id'] ); ?>][<?php echo esc_attr( $opt_key ); ?>][label]" value="<?php echo esc_attr( $opt ); ?>" class="field_<?php echo esc_attr( $field['id'] ); ?>_option <?php echo esc_attr( $field['separate_value'] ? 'frm_with_key' : '' ); ?>" id="<?php echo esc_attr( $html_id . '-' . $opt_key ); ?>" />
7
 
8
  <a href="javascript:void(0)" class="frm_icon_font frm_remove_tag" data-fid="<?php echo esc_attr( $field['id'] ); ?>" data-removeid="frm_delete_field_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>_container" data-removemore="#frm_<?php echo esc_attr( $default_type . '_' . $field['id'] . '-' . $opt_key ); ?>" data-showlast="#frm_add_opt_<?php echo esc_attr( $field['id'] ); ?>"></a>
9
 
10
  <span class="frm_option_key frm-with-right-icon field_<?php echo esc_attr( $field['id'] ); ?>_option_key<?php echo esc_attr( $field['separate_value'] ? '' : ' frm_hidden' ); ?>">
11
  <input type="<?php echo esc_attr( $default_type ); ?>" class="frm_invisible" />
12
- <input type="text" name="field_options[options_<?php echo esc_attr( $field['id'] ); ?>][<?php echo esc_attr( $opt_key ); ?>][value]" id="field_key_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>" value="<?php echo esc_attr( $field_val ); ?>" placeholder="<?php esc_attr_e( 'Saved Value', 'formidable' ); ?>"/>
13
- <i class="frm_icon_font frm_save_icon"></i>
14
  </span>
15
  </li>
1
  <li id="frm_delete_field_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>_container" data-optkey="<?php echo esc_attr( $opt_key ); ?>" class="frm_single_option <?php echo $opt_key === '000' ? 'frm_hidden frm_option_template' : ''; ?>">
2
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_drag_icon frm-drag' ); ?>
 
3
  <input type="<?php echo esc_attr( $default_type ); ?>" name="<?php echo esc_attr( $field_name ); ?>" <?php echo ( isset( $checked ) && $checked ? 'checked="checked"' : '' ); ?> value="<?php echo esc_attr( $field_val ); ?>"/>
4
 
5
+ <input type="text" name="field_options[options_<?php echo esc_attr( $field['id'] ); ?>][<?php echo esc_attr( $opt_key ); ?>][label]" value="<?php echo esc_attr( $opt ); ?>" class="field_<?php echo esc_attr( $field['id'] ); ?>_option <?php echo esc_attr( $field['separate_value'] ? 'frm_with_key' : '' ); ?>" id="<?php echo esc_attr( $html_id . '-' . $opt_key ); ?>" data-frmchange="trim" />
6
 
7
  <a href="javascript:void(0)" class="frm_icon_font frm_remove_tag" data-fid="<?php echo esc_attr( $field['id'] ); ?>" data-removeid="frm_delete_field_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>_container" data-removemore="#frm_<?php echo esc_attr( $default_type . '_' . $field['id'] . '-' . $opt_key ); ?>" data-showlast="#frm_add_opt_<?php echo esc_attr( $field['id'] ); ?>"></a>
8
 
9
  <span class="frm_option_key frm-with-right-icon field_<?php echo esc_attr( $field['id'] ); ?>_option_key<?php echo esc_attr( $field['separate_value'] ? '' : ' frm_hidden' ); ?>">
10
  <input type="<?php echo esc_attr( $default_type ); ?>" class="frm_invisible" />
11
+ <input type="text" name="field_options[options_<?php echo esc_attr( $field['id'] ); ?>][<?php echo esc_attr( $opt_key ); ?>][value]" id="field_key_<?php echo esc_attr( $field['id'] . '-' . $opt_key ); ?>" value="<?php echo esc_attr( $field_val ); ?>" placeholder="<?php esc_attr_e( 'Saved Value', 'formidable' ); ?>" data-frmchange="trim" />
12
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_save_icon' ); ?>
13
  </span>
14
  </li>
classes/views/frm-form-actions/_action_icon.php CHANGED
@@ -3,20 +3,16 @@
3
  data-limit="<?php echo esc_attr( $action_control->action_options['limit'] ); ?>"
4
  data-actiontype="<?php echo esc_attr( $action_control->id_base ); ?>"
5
  <?php
6
- foreach ( $data as $name => $value ) {
7
- echo esc_attr( $name ) . '="' . esc_attr( $value ) . '" ';
8
- }
9
  ?>
10
  >
11
- <span><i class="<?php echo esc_attr( $action_control->action_options['classes'] ); ?>"
12
- <?php
13
- if ( $action_control->action_options['color'] !== 'var(--primary-hover)' ) {
14
- ?>
15
- style="--primary-hover:<?php echo esc_attr( $action_control->action_options['color'] ); ?>"
16
- <?php
17
- }
18
- ?>
19
- ></i></span>
20
  <?php echo esc_html( str_replace( 'Add to ', '', $action_control->name ) ); ?>
21
  </a>
22
  </li>
3
  data-limit="<?php echo esc_attr( $action_control->action_options['limit'] ); ?>"
4
  data-actiontype="<?php echo esc_attr( $action_control->id_base ); ?>"
5
  <?php
6
+ echo FrmAppHelper::array_to_html_params( $data ); // WPCS: XSS ok.
 
 
7
  ?>
8
  >
9
+ <span class="frm-outer-circle">
10
+ <span class="frm-inner-circle<?php echo esc_attr( strpos( $action_control->action_options['classes'], 'frm-inverse' ) === false ? '' : ' frm-inverse' ); ?>" <?php
11
+ echo FrmAppHelper::array_to_html_params( $icon_atts ); // WPCS: XSS ok.
12
+ ?>>
13
+ <?php FrmAppHelper::icon_by_class( $action_control->action_options['classes'], $icon_atts ); ?>
14
+ </span>
15
+ </span>
 
 
16
  <?php echo esc_html( str_replace( 'Add to ', '', $action_control->name ) ); ?>
17
  </a>
18
  </li>
classes/views/frm-form-actions/_action_inside.php CHANGED
@@ -93,7 +93,7 @@ if ( $use_logging ) {
93
  ?>
94
  <p>
95
  <a href="javascript:void(0)" class="frm_show_upgrade" data-upgrade="<?php esc_attr_e( 'Form action logs', 'formidable' ); ?>" data-medium="action-logs" data-oneclick="<?php echo esc_attr( json_encode( $upgrading ) ); ?>">
96
- <i class="frm_icon_font frm_tooltip_solid_icon"></i>
97
  <?php esc_html_e( 'Install logging to get more information on API requests.', 'formidable' ); ?>
98
  </a>
99
  </p>
93
  ?>
94
  <p>
95
  <a href="javascript:void(0)" class="frm_show_upgrade" data-upgrade="<?php esc_attr_e( 'Form action logs', 'formidable' ); ?>" data-medium="action-logs" data-oneclick="<?php echo esc_attr( json_encode( $upgrading ) ); ?>">
96
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_tooltip_solid_icon frm_svg15', array( 'aria-hidden' => 'true' ) ); ?>
97
  <?php esc_html_e( 'Install logging to get more information on API requests.', 'formidable' ); ?>
98
  </a>
99
  </p>
classes/views/frm-form-actions/form_action.php CHANGED
@@ -14,9 +14,13 @@ $form_action = apply_filters( 'frm_form_' . $form_action->post_excerpt . '_actio
14
  </div>
15
  <span class="frm_email_icons alignright">
16
  <?php if ( $action_control->action_options['limit'] > 2 ) { ?>
17
- <a href="javascript:void(0)" class="frm_icon_font frm_clone_solid_icon frm_duplicate_form_action" title="<?php esc_attr_e( 'Duplicate', 'formidable' ); ?>"> </a>
 
 
18
  <?php } ?>
19
- <a href="javascript:void(0)" data-removeid="frm_form_action_<?php echo esc_attr( $action_key ); ?>" class="frm_icon_font frm_delete_icon frm_remove_form_action" data-frmverify="<?php echo esc_attr( 'Delete this form action?', 'formidable' ); ?>" title="<?php esc_attr_e( 'Delete', 'formidable' ); ?>"> </a>
 
 
20
 
21
  <label class="frm_toggle">
22
  <input type="checkbox" value="publish" name="<?php echo esc_attr( $action_control->get_field_name( 'post_status', '' ) ); ?>" <?php checked( $form_action->post_status, 'publish' ); ?> />
@@ -26,7 +30,10 @@ $form_action = apply_filters( 'frm_form_' . $form_action->post_excerpt . '_actio
26
  </label>
27
  </span>
28
  <div class="widget-title">
29
- <h4><span class="frm_form_action_icon <?php echo esc_attr( $action_control->action_options['classes'] ); ?>"></span>
 
 
 
30
  <?php echo esc_html( $form_action->post_title ); ?>
31
  </h4>
32
  </div>
14
  </div>
15
  <span class="frm_email_icons alignright">
16
  <?php if ( $action_control->action_options['limit'] > 2 ) { ?>
17
+ <a href="javascript:void(0)" class="frm_duplicate_form_action" title="<?php esc_attr_e( 'Duplicate', 'formidable' ); ?>">
18
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_clone_solid_icon' ); ?>
19
+ </a>
20
  <?php } ?>
21
+ <a href="javascript:void(0)" data-removeid="frm_form_action_<?php echo esc_attr( $action_key ); ?>" class="frm_remove_form_action" data-frmverify="<?php echo esc_attr( 'Delete this form action?', 'formidable' ); ?>" title="<?php esc_attr_e( 'Delete', 'formidable' ); ?>">
22
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_delete_icon ' ); ?>
23
+ </a>
24
 
25
  <label class="frm_toggle">
26
  <input type="checkbox" value="publish" name="<?php echo esc_attr( $action_control->get_field_name( 'post_status', '' ) ); ?>" <?php checked( $form_action->post_status, 'publish' ); ?> />
30
  </label>
31
  </span>
32
  <div class="widget-title">
33
+ <h4>
34
+ <span class="frm_form_action_icon frm-outer-circle <?php echo esc_attr( strpos( $action_control->action_options['classes'], 'frm-inverse' ) === false ? '' : ' frm-inverse' ); ?>">
35
+ <?php FrmAppHelper::icon_by_class( $action_control->action_options['classes'] ); ?>
36
+ </span>
37
  <?php echo esc_html( $form_action->post_title ); ?>
38
  </h4>
39
  </div>
classes/views/frm-form-actions/settings.php CHANGED
@@ -50,11 +50,20 @@
50
  ?>
51
  <li class="frm-action frm-not-installed">
52
  <a href="javascript:void(0)" class="frm-single-action frm_show_upgrade">
53
- <span>
54
- <i class="frm_icon_font frm_plus_icon"
55
- <?php if ( isset( $group['color'] ) ) { ?>
56
- style="--primary-hover:<?php echo esc_attr( $group['color'] ); ?>"
57
- <?php } ?>></i>
 
 
 
 
 
 
 
 
 
58
  </span>
59
  <?php echo esc_html( $action ); ?>
60
  </a>
50
  ?>
51
  <li class="frm-action frm-not-installed">
52
  <a href="javascript:void(0)" class="frm-single-action frm_show_upgrade">
53
+ <span class="frm-outer-circle">
54
+ <span class="frm-inner-circle" <?php
55
+ echo FrmAppHelper::array_to_html_params( $icon_atts ); // WPCS: XSS ok.
56
+ ?>>
57
+ <?php
58
+ $icon_atts = array();
59
+ if ( isset( $group['color'] ) ) {
60
+ $icon_atts = array(
61
+ 'style' => '--primary-hover:' . $group['color'],
62
+ );
63
+ }
64
+ FrmAppHelper::icon_by_class( 'frmfont frm_plus_icon', $icon_atts );
65
+ ?>
66
+ </span>
67
  </span>
68
  <?php echo esc_html( $action ); ?>
69
  </a>
classes/views/frm-forms/_publish_box.php CHANGED
@@ -14,7 +14,7 @@ if ( 'settings' == FrmAppHelper::simple_get( 'frm_action', 'sanitize_title' ) )
14
  <div class="preview dropdown">
15
  <a href="#" id="frm-previewDrop" class="frm-dropdown-toggle button frm-button-secondary" data-toggle="dropdown">
16
  <?php esc_html_e( 'Preview', 'formidable' ); ?>
17
- <i class="frmfont frm_arrowdown4_icon"></i>
18
  </a>
19
 
20
  <ul class="frm-dropdown-menu <?php echo esc_attr( is_rtl() ? 'pull-left' : 'pull-right' ); ?>" role="menu" aria-labelledby="frm-previewDrop">
14
  <div class="preview dropdown">
15
  <a href="#" id="frm-previewDrop" class="frm-dropdown-toggle button frm-button-secondary" data-toggle="dropdown">
16
  <?php esc_html_e( 'Preview', 'formidable' ); ?>
17
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_arrowdown4_icon frm_svg13', array( 'aria-hidden' => 'true' ) ); ?>
18
  </a>
19
 
20
  <ul class="frm-dropdown-menu <?php echo esc_attr( is_rtl() ? 'pull-left' : 'pull-right' ); ?>" role="menu" aria-labelledby="frm-previewDrop">
classes/views/frm-forms/add_field.php CHANGED
@@ -12,9 +12,15 @@
12
  <a href="#" class="frm-collapse-section frm-hover-icon frm_icon_font frm_arrowdown6_icon" title="<?php esc_attr_e( 'Expand/Collapse Section', 'formidable' ); ?>"></a>
13
  <?php } ?>
14
 
15
- <a href="#" class="frm_bstooltip frm-move frm-hover-icon frm_icon_font frm_move_icon" title="<?php esc_attr_e( 'Move Field', 'formidable' ); ?>"> </a>
16
- <a href="#" class="frm_bstooltip frm-hover-icon frm_icon_font frm_delete_icon frm_delete_field" title="<?php esc_attr_e( 'Delete Field', 'formidable' ); ?>"> </a>
17
- <a href="#" class="frm_bstooltip frm-hover-icon frm_icon_font frm_clone_icon" title="<?php ( $field['type'] === 'divider' ) ? esc_attr_e( 'Duplicate Section', 'formidable' ) : esc_attr_e( 'Duplicate Field', 'formidable' ); ?>"> </a>
 
 
 
 
 
 
18
 
19
  <div class="frm-sub-label alignright">
20
  (ID <?php echo esc_html( $field['id'] ); ?>)
@@ -36,7 +42,7 @@
36
  <div class="clear"></div>
37
  </div>
38
  <?php if ( $display['description'] || in_array( $field['type'], array( 'address', 'credit_card' ) ) ) { ?>
39
- <div class="description" id="field_description_<?php echo esc_attr( $field['id'] ); ?>">
40
  <?php echo FrmAppHelper::kses( force_balance_tags( $field['description'] ), 'all' ); // WPCS: XSS ok. ?>
41
  </div>
42
  <?php } ?>
@@ -48,7 +54,7 @@
48
  <div class="frm_form_fields">
49
  <input type="text" id="conf_field_<?php echo esc_attr( $field['field_key'] ); ?>" name="field_options[conf_input_<?php echo esc_attr( $field['id'] ); ?>]" placeholder="<?php echo esc_attr( $field['conf_input'] ); ?>" class="dyn_default_value" />
50
  </div>
51
- <div id="conf_field_description_<?php echo esc_attr( $field['id'] ); ?>" class="description"><?php
52
  echo FrmAppHelper::kses( force_balance_tags( $field['conf_desc'] ), 'all' ); // WPCS: XSS ok.
53
  ?></div>
54
  </div>
@@ -63,7 +69,7 @@ if ( 'divider' === $field['type'] ) {
63
  ?>
64
  </div>
65
  <div class="frm_no_section_fields">
66
- <i class="frm-large-plus frm_icon_font frm_plus2_icon"></i>
67
  <p class="howto"><?php esc_html_e( 'Your section has no fields. Drag fields here to add them to this section.', 'formidable' ); ?></p>
68
  </div>
69
  <ul class="start_divider frm_sorting">
12
  <a href="#" class="frm-collapse-section frm-hover-icon frm_icon_font frm_arrowdown6_icon" title="<?php esc_attr_e( 'Expand/Collapse Section', 'formidable' ); ?>"></a>
13
  <?php } ?>
14
 
15
+ <a href="#" class="frm_bstooltip frm-move frm-hover-icon" title="<?php esc_attr_e( 'Move Field', 'formidable' ); ?>">
16
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_move_icon' ); ?>
17
+ </a>
18
+ <a href="#" class="frm_bstooltip frm-hover-icon frm_delete_field" title="<?php esc_attr_e( 'Delete Field', 'formidable' ); ?>">
19
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_delete_icon' ); ?>
20
+ </a>
21
+ <a href="#" class="frm_bstooltip frm-hover-icon frm_clone_field" title="<?php ( $field['type'] === 'divider' ) ? esc_attr_e( 'Duplicate Section', 'formidable' ) : esc_attr_e( 'Duplicate Field', 'formidable' ); ?>">
22
+ <?php FrmAppHelper::icon_by_class( 'frm_icon_font frm_clone_icon' ); ?>
23
+ </a>
24
 
25
  <div class="frm-sub-label alignright">
26
  (ID <?php echo esc_html( $field['id'] ); ?>)
42
  <div class="clear"></div>
43
  </div>
44
  <?php if ( $display['description'] || in_array( $field['type'], array( 'address', 'credit_card' ) ) ) { ?>
45
+ <div class="description frm_description" id="field_description_<?php echo esc_attr( $field['id'] ); ?>">
46
  <?php echo FrmAppHelper::kses( force_balance_tags( $field['description'] ), 'all' ); // WPCS: XSS ok. ?>
47
  </div>
48
  <?php } ?>
54
  <div class="frm_form_fields">
55
  <input type="text" id="conf_field_<?php echo esc_attr( $field['field_key'] ); ?>" name="field_options[conf_input_<?php echo esc_attr( $field['id'] ); ?>]" placeholder="<?php echo esc_attr( $field['conf_input'] ); ?>" class="dyn_default_value" />
56
  </div>
57
+ <div id="conf_field_description_<?php echo esc_attr( $field['id'] ); ?>" class="description frm_description"><?php
58
  echo FrmAppHelper::kses( force_balance_tags( $field['conf_desc'] ), 'all' ); // WPCS: XSS ok.
59
  ?></div>
60
  </div>
69
  ?>
70
  </div>
71
  <div class="frm_no_section_fields">
72
+ <?php FrmAppHelper::icon_by_class( 'frmfont frm_plus2_icon frm-large-plus', array( 'aria-hidden' => 'true' ) ); ?>
73
  <p class="howto"><?php esc_html_e( 'Your section has no fields. Drag fields here to add them to this section.', 'formidable' ); ?></p>
74
  </div>
75
  <ul class="start_divider frm_sorting">
classes/views/frm-forms/add_field_links.php CHANGED
@@ -22,7 +22,7 @@
22
  ?>
23
  <li class="frmbutton <?php echo esc_attr( ' frm_t' . $field_key ); ?>" id="<?php echo esc_attr( $field_key ); ?>">
24
  <a href="#" class="frm_add_field frm_animate_bg" title="<?php echo esc_html( $field_label ); ?>">
25
- <i class="<?php echo esc_attr( FrmFormsHelper::get_field_link_icon( $field_type ) ); ?> frm_animate_bg"></i>
26
  <span><?php echo esc_html( $field_label ); ?></span>
27
  </a>
28
  </li>
@@ -57,7 +57,7 @@ foreach ( FrmField::pro_field_selection() as $field_key => $field_type ) {
57
  ?>
58
  <li class="frmbutton <?php echo esc_attr( $no_allow_class . ' frm_t' . $field_key ); ?> dropdown" id="<?php echo esc_attr( $field_key ); ?>">
59
  <a href="#" id="frm-<?php echo esc_attr( $field_key ); ?>Drop" class="frm-dropdown-toggle" data-toggle="dropdown" title="<?php echo esc_html( $field_label ); ?>">
60
- <i class="<?php echo esc_attr( FrmFormsHelper::get_field_link_icon( $field_type ) ); ?> frm_animate_bg"></i>
61
  <span><?php echo esc_html( $field_label ); ?> <b class="caret"></b></span>
62
  </a>
63
 
@@ -74,7 +74,7 @@ foreach ( FrmField::pro_field_selection() as $field_key => $field_type ) {
74
  </li>
75
  <?php
76
  } else {
77
- $field_label = '<i class="' . esc_attr( FrmFormsHelper::get_field_link_icon( $field_type ) ) . ' frm_animate_bg"></i>';
78
  $field_name = FrmFormsHelper::get_field_link_name( $field_type );
79
  $field_label .= ' <span>' . $field_name . '</span>';
80
 
@@ -102,10 +102,9 @@ foreach ( FrmField::pro_field_selection() as $field_key => $field_type ) {
102
  <li class="frmbutton <?php echo esc_attr( $no_allow_class . $single_no_allow . ' frm_t' . str_replace( '|', '-', $field_key ) ); ?>" id="<?php echo esc_attr( $field_key ); ?>" data-upgrade="<?php echo esc_attr( $upgrade_label ); ?>" data-medium="builder" data-oneclick="<?php echo esc_attr( $install_data ); ?>" data-content="<?php echo esc_attr( $field_key ); ?>" data-requires="<?php echo esc_attr( $requires ); ?>">
103
  <?php
104
  if ( $run_filter ) {
105
- echo FrmAppHelper::kses( apply_filters( 'frmpro_field_links', $field_label, $id, $field_key ), array( 'a', 'i', 'span' ) ); // WPCS: XSS ok.
106
- } else {
107
- echo FrmAppHelper::kses( $field_label, array( 'i', 'span' ) ); // WPCS: XSS ok.
108
  }
 
109
  ?>
110
  </li>
111
  <?php
22
  ?>
23
  <li class="frmbutton <?php echo esc_attr( ' frm_t' . $field_key ); ?>" id="<?php echo esc_attr( $field_key ); ?>">
24
  <a href="#" class="frm_add_field frm_animate_bg" title="<?php echo esc_html( $field_label ); ?>">
25
+ <?php FrmAppHelper::icon_by_class( FrmFormsHelper::get_field_link_icon( $field_type ) ); ?>
26
  <span><?php echo esc_html( $field_label ); ?></span>
27
  </a>
28
  </li>
57
  ?>
58
  <li class="frmbutton <?php echo esc_attr( $no_allow_class . ' frm_t' . $field_key ); ?> dropdown" id="<?php echo esc_attr( $field_key ); ?>">
59
  <a href="#" id="frm-<?php echo esc_attr( $field_key ); ?>Drop" class="frm-dropdown-toggle" data-toggle="dropdown" title="<?php echo esc_html( $field_label ); ?>">
60
+ <?php FrmAppHelper::icon_by_class( FrmFormsHelper::get_field_link_icon( $field_type ) ); ?>
61
  <span><?php echo esc_html( $field_label ); ?> <b class="caret"></b></span>
62
  </a>
63
 
74
  </li>
75
  <?php
76
  } else {
77
+ $field_label = FrmAppHelper::icon_by_class( FrmFormsHelper::get_field_link_icon( $field_type ), array( 'echo' => false ) );
78
  $field_name = FrmFormsHelper::get_field_link_name( $field_type );
79
  $field_label .= ' <span>' . $field_name . '</span>';
80
 
102
  <li class="frmbutton <?php echo esc_attr( $no_allow_class . $single_no_allow . ' frm_t' . str_replace( '|', '-', $field_key ) ); ?>" id="<?php echo esc_attr( $field_key ); ?>" data-upgrade="<?php echo esc_attr( $upgrade_label ); ?>" data-medium="builder" data-oneclick="<?php echo esc_attr( $install_data ); ?>" data-content="<?php echo esc_attr( $field_key ); ?>" data-requires="<?php echo esc_attr( $requires ); ?>">
103
  <?php
104
  if ( $run_filter ) {
105
+ $field_label = apply_filters( 'frmpro_field_links', $field_label, $id, $field_key );
 
 
106
  }
107
+ echo FrmAppHelper::kses( $field_label, array( 'a', 'i', 'span', 'use', 'svg' ) ); // WPCS: XSS ok.
108
  ?>
109
  </li>
110
  <?php
classes/views/frm-forms/form.php CHANGED
@@ -1,8 +1,10 @@
1
- <div id="frm_form_editor_container" class="<?php echo ( isset( $values['fields'] ) && ! empty( $values['fields'] ) ) ? 'frm-has-fields' : ''; ?>">
2
 
3
  <?php
4
- // Add form messages.
5
- require( FrmAppHelper::plugin_path() . '/classes/views/shared/errors.php' );
 
 
6
  ?>
7
 
8
  <div id="frm-fake-page" class="frm_hidden">
1
+ <div id="frm_form_editor_container" class="<?php echo ( $has_fields ? 'frm-has-fields' : '' ); ?>">
2
 
3
  <?php
4
+ if ( $has_fields ) {
5
+ // Add form messages.
6
+ require( FrmAppHelper::plugin_path() . '/classes/views/shared/errors.php' );
7
+ }
8
  ?>
9
 
10
  <div id="frm-fake-page" class="frm_hidden">
classes/views/frm-forms/settings-advanced.php CHANGED
@@ -79,7 +79,7 @@
79
  </select>
80
  </p>
81
  <p class="frm8 frm_form_field">
82
- <span class="success_action_redirect_box success_action_box<?php echo ( $values['success_action'] == 'redirect' ) ? '' : ' frm_hidden'; ?>">
83
  <input type="text" name="options[success_url]" id="success_url" value="<?php echo esc_attr( isset( $values['success_url'] ) ? $values['success_url'] : '' ); ?>" placeholder="http://example.com" />
84
  </span>
85
 
@@ -88,7 +88,7 @@
88
  FrmAppHelper::wp_pages_dropdown(
89
  array(
90
  'field_name' => 'options[success_page_id]',
91
- 'page_id' => $values['success_page_id'],
92
  'placeholder' => __( 'Select a Page', 'formidable' ),
93
  )
94
  );
@@ -97,16 +97,16 @@
97
  </p>
98
 
99
  <p class="frm_show_form_opt success_action_message_box success_action_box<?php echo esc_attr( $values['success_action'] == 'message' ? '' : ' frm_hidden' ); ?>">
100
- <label for="show_form">
101
- <input type="checkbox" name="options[show_form]" id="show_form" value="1" <?php checked( $values['show_form'], 1 ); ?> />
102
- <?php esc_html_e( 'Show the form with the confirmation message', 'formidable' ); ?>
103
- </label>
104
  </p>
105
 
106
  <table class="form-table">
107
  <tr>
108
  <td colspan="2">
109
- <label for="no_save">
110
  <input type="checkbox" name="options[no_save]" id="no_save" value="1" <?php checked( $values['no_save'], 1 ); ?> />
111
  <?php esc_html_e( 'Do not store entries submitted from this form', 'formidable' ); ?>
112
  </label>
@@ -139,7 +139,7 @@
139
  <table class="form-table">
140
  <tr>
141
  <td>
142
- <label for="ajax_load">
143
  <input type="checkbox" name="options[ajax_load]" id="ajax_load" value="1"<?php echo ( $values['ajax_load'] ) ? ' checked="checked"' : ''; ?> /> <?php esc_html_e( 'Load and save form builder page with AJAX', 'formidable' ); ?>
144
  <span class="frm_help frm_icon_font frm_tooltip_icon" title="<?php esc_attr_e( 'Recommended for long forms.', 'formidable' ); ?>"></span>
145
  </label>
@@ -148,7 +148,7 @@
148
  <?php do_action( 'frm_add_form_ajax_options', $values ); ?>
149
  <tr>
150
  <td>
151
- <label for="js_validate">
152
  <input type="checkbox" name="options[js_validate]" id="js_validate" value="1" <?php checked( $values['js_validate'], 1 ); ?> />
153
  <?php esc_html_e( 'Validate this form with javascript', 'formidable' ); ?>
154
  <span class="frm_help frm_icon_font frm_tooltip_icon" title="<?php esc_attr_e( 'Required fields, email format, and number format can be checked instantly in your browser. You may want to turn this option off if you have any customizations to remove validation messages on certain fields.', 'formidable' ); ?>"></span>
79
  </select>
80
  </p>
81
  <p class="frm8 frm_form_field">
82
+ <span class="frm_has_shortcodes success_action_redirect_box success_action_box<?php echo ( $values['success_action'] == 'redirect' ) ? '' : ' frm_hidden'; ?>">
83
  <input type="text" name="options[success_url]" id="success_url" value="<?php echo esc_attr( isset( $values['success_url'] ) ? $values['success_url'] : '' ); ?>" placeholder="http://example.com" />
84
  </span>
85
 
88
  FrmAppHelper::wp_pages_dropdown(
89
  array(
90
  'field_name' => 'options[success_page_id]',
91
+ 'page_id' => isset( $values['success_page_id'] ) ? $values['success_page_id'] : '',
92
  'placeholder' => __( 'Select a Page', 'formidable' ),
93
  )
94
  );
97
  </p>
98
 
99
  <p class="frm_show_form_opt success_action_message_box success_action_box<?php echo esc_attr( $values['success_action'] == 'message' ? '' : ' frm_hidden' ); ?>">
100
+ <label for="show_form" class="frm_inline_block">
101
+ <input type="checkbox" name="options[show_form]" id="show_form" value="1" <?php checked( $values['show_form'], 1 ); ?> />
102
+ <?php esc_html_e( 'Show the form with the confirmation message', 'formidable' ); ?>
103
+ </label>
104
  </p>
105
 
106
  <table class="form-table">
107
  <tr>
108
  <td colspan="2">
109
+ <label for="no_save" class="frm_inline_block">
110
  <input type="checkbox" name="options[no_save]" id="no_save" value="1" <?php checked( $values['no_save'], 1 ); ?> />
111
  <?php esc_html_e( 'Do not store entries submitted from this form', 'formidable' ); ?>
112
  </label>
139
  <table class="form-table">
140
  <tr>
141
  <td>
142
+ <label for="ajax_load" class="frm_inline_block">
143
  <input type="checkbox" name="options[ajax_load]" id="ajax_load" value="1"<?php echo ( $values['ajax_load'] ) ? ' checked="checked"' : ''; ?> /> <?php esc_html_e( 'Load and save form builder page with AJAX', 'formidable' ); ?>
144
  <span class="frm_help frm_icon_font frm_tooltip_icon" title="<?php esc_attr_e( 'Recommended for long forms.', 'formidable' ); ?>"></span>
145
  </label>
148
  <?php do_action( 'frm_add_form_ajax_options', $values ); ?>
149
  <tr>
150
  <td>
151
+ <label for="js_validate" class="frm_inline_block">
152
  <input type="checkbox" name="options[js_validate]" id="js_validate" value="1" <?php checked( $values['js_validate'], 1 ); ?> />
153
  <?php esc_html_e( 'Validate this form with javascript', 'formidable' ); ?>
154
  <span class="frm_help frm_icon_font frm_tooltip_icon" title="<?php esc_attr_e( 'Required fields, email format, and number format can be checked instantly in your browser. You may want to turn this option off if you have any customizations to remove validation messages on certain fields.', 'formidable' ); ?>"></span>
classes/views/frm-settings/form.php CHANGED
@@ -1,26 +1,24 @@
1
  <div id="form_global_settings" class="frm_wrap">
2
- <div class="frm_page_container">
 
 
3
 
4
- <?php
5
- FrmAppHelper::get_admin_header(
6
- array(
7
- 'label' => __( 'Settings', 'formidable' ),
8
- )
9
- );
10
- ?>
11
-
12
- <div class="columns-2">
13
- <div class="frm-right-panel">
14
  <?php
15
- $current = FrmAppHelper::simple_get( 't', 'sanitize_title', 'general_settings' );
16
- include( FrmAppHelper::plugin_path() . '/classes/views/frm-settings/tabs.php' );
 
 
 
 
17
  ?>
18
- </div>
19
 
20
- <div id="post-body-content" class="frm-fields">