Formidable Forms – Form Builder for WordPress - Version 4.07.01

Version Description

  • New: Show a warning when leaving the builder page with unsaved changes.
  • Fix: Make any multiselect dropdowns in admin settings accessible.
  • Fix: aria-invalid attribute was missing on elements for accessibility.
Download this release

Release Info

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

Code changes from version 4.07 to 4.07.01

Files changed (198) hide show
  1. classes/controllers/FrmAddonsController.php +3 -0
  2. classes/controllers/FrmAppController.php +3 -0
  3. classes/controllers/FrmEntriesController.php +3 -0
  4. classes/controllers/FrmFieldsController.php +3 -0
  5. classes/controllers/FrmFormActionsController.php +3 -0
  6. classes/controllers/FrmFormsController.php +3 -0
  7. classes/controllers/FrmHooksController.php +3 -0
  8. classes/controllers/FrmInboxController.php +4 -0
  9. classes/controllers/FrmSMTPController.php +3 -0
  10. classes/controllers/FrmSettingsController.php +3 -0
  11. classes/controllers/FrmSimpleBlocksController.php +3 -0
  12. classes/controllers/FrmStylesController.php +3 -0
  13. classes/controllers/FrmXMLController.php +3 -0
  14. classes/factories/FrmEntryFactory.php +3 -0
  15. classes/factories/FrmFieldFactory.php +3 -0
  16. classes/helpers/FrmAppHelper.php +8 -1
  17. classes/helpers/FrmCSVExportHelper.php +3 -0
  18. classes/helpers/FrmEmailHelper.php +3 -0
  19. classes/helpers/FrmEntriesListHelper.php +3 -0
  20. classes/helpers/FrmShortcodeHelper.php +4 -0
  21. classes/helpers/FrmStylesHelper.php +3 -0
  22. classes/helpers/FrmTipsHelper.php +3 -0
  23. classes/helpers/FrmXMLHelper.php +48 -1
  24. classes/models/FrmAddon.php +0 -1
  25. classes/models/FrmCreateFile.php +0 -1
  26. classes/models/FrmDb.php +3 -0
  27. classes/models/FrmEmail.php +3 -0
  28. classes/models/FrmEntryFormatter.php +3 -0
  29. classes/models/FrmEntryShortcodeFormatter.php +3 -0
  30. classes/models/FrmEntryValidate.php +3 -0
  31. classes/models/FrmEntryValues.php +3 -0
  32. classes/models/FrmFieldFormHtml.php +5 -3
  33. classes/models/FrmFieldOption.php +3 -0
  34. classes/models/FrmFieldValue.php +3 -0
  35. classes/models/FrmFieldValueSelector.php +3 -0
  36. classes/models/FrmFormAction.php +3 -0
  37. classes/models/FrmFormApi.php +3 -0
  38. classes/models/FrmFormMigrator.php +3 -0
  39. classes/models/FrmFormTemplateApi.php +3 -0
  40. classes/models/FrmInbox.php +4 -0
  41. classes/models/FrmInstallPlugin.php +3 -0
  42. classes/models/FrmMigrate.php +3 -4
  43. classes/models/FrmNotification.php +3 -4
  44. classes/models/FrmPersonalData.php +3 -0
  45. classes/models/FrmReviews.php +3 -0
  46. classes/models/FrmSettings.php +3 -0
  47. classes/models/FrmStyle.php +3 -0
  48. classes/models/FrmTableHTMLGenerator.php +3 -0
  49. classes/models/FrmUsage.php +1 -0
  50. classes/models/fields/FrmFieldCaptcha.php +3 -0
  51. classes/models/fields/FrmFieldCheckbox.php +3 -0
  52. classes/models/fields/FrmFieldDefault.php +3 -0
  53. classes/models/fields/FrmFieldEmail.php +3 -0
  54. classes/models/fields/FrmFieldHTML.php +3 -0
  55. classes/models/fields/FrmFieldHidden.php +3 -0
  56. classes/models/fields/FrmFieldNumber.php +3 -0
  57. classes/models/fields/FrmFieldPhone.php +3 -0
  58. classes/models/fields/FrmFieldRadio.php +3 -0
  59. classes/models/fields/FrmFieldSelect.php +3 -0
  60. classes/models/fields/FrmFieldText.php +3 -0
  61. classes/models/fields/FrmFieldTextarea.php +3 -0
  62. classes/models/fields/FrmFieldType.php +3 -0
  63. classes/models/fields/FrmFieldUrl.php +3 -0
  64. classes/models/fields/FrmFieldUserID.php +3 -0
  65. classes/views/addons/list.php +5 -0
  66. classes/views/addons/settings.php +5 -0
  67. classes/views/addons/upgrade_to_pro.php +5 -0
  68. classes/views/frm-entries/_sidebar-shared-pub.php +4 -0
  69. classes/views/frm-entries/direct.php +5 -0
  70. classes/views/frm-entries/errors.php +4 -0
  71. classes/views/frm-entries/form.php +4 -0
  72. classes/views/frm-entries/list.php +5 -0
  73. classes/views/frm-entries/new.php +5 -0
  74. classes/views/frm-entries/no_entries.php +5 -0
  75. classes/views/frm-entries/show.php +5 -0
  76. classes/views/frm-entries/sidebar-shared.php +5 -0
  77. classes/views/frm-entries/sidebar-show.php +4 -0
  78. classes/views/frm-fields/back-end/ajax-field-placeholder.php +5 -0
  79. classes/views/frm-fields/back-end/automatic-width.php +5 -0
  80. classes/views/frm-fields/back-end/bulk-options-overlay.php +5 -0
  81. classes/views/frm-fields/back-end/dropdown-field.php +3 -0
  82. classes/views/frm-fields/back-end/field-captcha.php +4 -0
  83. classes/views/frm-fields/back-end/field-choices.php +4 -0
  84. classes/views/frm-fields/back-end/field-description.php +5 -0
  85. classes/views/frm-fields/back-end/field-hidden.php +5 -0
  86. classes/views/frm-fields/back-end/field-html.php +5 -0
  87. classes/views/frm-fields/back-end/field-multiple.php +4 -1
  88. classes/views/frm-fields/back-end/field-options.php +5 -0
  89. classes/views/frm-fields/back-end/field-user-id.php +5 -0
  90. classes/views/frm-fields/back-end/html-content.php +5 -0
  91. classes/views/frm-fields/back-end/inline-modal.php +5 -0
  92. classes/views/frm-fields/back-end/input-mask-info.php +5 -0
  93. classes/views/frm-fields/back-end/layout-classes.php +5 -0
  94. classes/views/frm-fields/back-end/max.php +5 -0
  95. classes/views/frm-fields/back-end/number-range.php +5 -0
  96. classes/views/frm-fields/back-end/pixels-wide.php +5 -0
  97. classes/views/frm-fields/back-end/radio-field.php +3 -0
  98. classes/views/frm-fields/back-end/radio-images.php +5 -0
  99. classes/views/frm-fields/back-end/settings.php +5 -0
  100. classes/views/frm-fields/back-end/smart-values.php +5 -0
  101. classes/views/frm-fields/back-end/value-format.php +5 -0
  102. classes/views/frm-fields/front-end/checkbox-field.php +4 -0
  103. classes/views/frm-fields/front-end/dropdown-field.php +3 -0
  104. classes/views/frm-fields/front-end/radio-field.php +4 -0
  105. classes/views/frm-fields/input.php +4 -0
  106. classes/views/frm-fields/radio.php +4 -0
  107. classes/views/frm-fields/show-build.php +3 -0
  108. classes/views/frm-fields/single-option.php +5 -0
  109. classes/views/frm-form-actions/_action_icon.php +5 -0
  110. classes/views/frm-form-actions/_action_inside.php +6 -0
  111. classes/views/frm-form-actions/_email_settings.php +6 -0
  112. classes/views/frm-form-actions/default_actions.php +4 -0
  113. classes/views/frm-form-actions/email_action.php +4 -1
  114. classes/views/frm-form-actions/form_action.php +4 -0
  115. classes/views/frm-form-actions/settings.php +6 -1
  116. classes/views/frm-forms/_no_forms.php +5 -0
  117. classes/views/frm-forms/_publish_box.php +4 -0
  118. classes/views/frm-forms/actions-dropdown.php +5 -0
  119. classes/views/frm-forms/add_field.php +5 -0
  120. classes/views/frm-forms/add_field_links.php +5 -0
  121. classes/views/frm-forms/add_form_style_options.php +5 -0
  122. classes/views/frm-forms/edit.php +5 -0
  123. classes/views/frm-forms/form.php +8 -1
  124. classes/views/frm-forms/insert_form_popup.php +5 -0
  125. classes/views/frm-forms/list-templates.php +5 -0
  126. classes/views/frm-forms/list.php +6 -1
  127. classes/views/frm-forms/mb_html_tab.php +5 -0
  128. classes/views/frm-forms/mb_insert_fields.php +5 -0
  129. classes/views/frm-forms/multiselect-accessibility.php +10 -0
  130. classes/views/frm-forms/new-form-overlay.php +5 -0
  131. classes/views/frm-forms/new.php +4 -0
  132. classes/views/frm-forms/settings-advanced.php +5 -0
  133. classes/views/frm-forms/settings-buttons.php +5 -0
  134. classes/views/frm-forms/settings-html.php +5 -0
  135. classes/views/frm-forms/settings.php +8 -0
  136. classes/views/frm-forms/shortcode_opts.php +4 -0
  137. classes/views/frm-forms/sidebar-settings.php +5 -1
  138. classes/views/frm-forms/template-name-overlay.php +5 -1
  139. classes/views/frm-settings/form.php +5 -0
  140. classes/views/frm-settings/general.php +5 -0
  141. classes/views/frm-settings/license_box.php +5 -0
  142. classes/views/frm-settings/messages.php +5 -0
  143. classes/views/frm-settings/misc.php +5 -0
  144. classes/views/frm-settings/permissions.php +9 -1
  145. classes/views/frm-settings/recaptcha.php +5 -0
  146. classes/views/frm-settings/settings_cta.php +5 -0
  147. classes/views/frm-settings/tabs.php +5 -0
  148. classes/views/inbox/list.php +5 -0
  149. classes/views/shared/admin-header.php +5 -0
  150. classes/views/shared/confirm-overlay.php +5 -0
  151. classes/views/shared/errors.php +4 -0
  152. classes/views/shared/form-nav.php +7 -1
  153. classes/views/shared/info-overlay.php +5 -0
  154. classes/views/shared/mb_adv_info.php +5 -0
  155. classes/views/shared/reports-info.php +5 -0
  156. classes/views/shared/review.php +5 -0
  157. classes/views/shared/upgrade_overlay.php +5 -0
  158. classes/views/shared/views-info.php +5 -0
  159. classes/views/solutions/_import.php +5 -0
  160. classes/views/styles/_buttons.php +5 -0
  161. classes/views/styles/_check-box-radio-fields.php +5 -0
  162. classes/views/styles/_field-colors.php +5 -0
  163. classes/views/styles/_field-description.php +5 -0
  164. classes/views/styles/_field-labels.php +5 -0
  165. classes/views/styles/_field-sizes.php +5 -0
  166. classes/views/styles/_form-description.php +5 -0
  167. classes/views/styles/_form-messages.php +5 -0
  168. classes/views/styles/_form-title.php +5 -0
  169. classes/views/styles/_general.php +5 -0
  170. classes/views/styles/_sample_form.php +5 -0
  171. classes/views/styles/custom_css.php +5 -0
  172. classes/views/styles/header-buttons.php +5 -0
  173. classes/views/styles/manage.php +5 -0
  174. classes/views/styles/show.php +5 -0
  175. classes/views/xml/forms_xml.php +4 -0
  176. classes/views/xml/import_form.php +5 -0
  177. classes/views/xml/posts_xml.php +4 -0
  178. classes/views/xml/xml.php +7 -1
  179. classes/widgets/FrmShowForm.php +3 -0
  180. css/_single_theme.css.php +3 -0
  181. css/custom_theme.css.php +4 -0
  182. css/frm_admin.css +7 -1
  183. deprecated.php +8 -5
  184. deprecated/FrmDbDeprecated.php +3 -0
  185. deprecated/FrmDeprecated.php +3 -0
  186. deprecated/FrmEntryDeprecated.php +3 -0
  187. deprecated/FrmEntryFormat.php +4 -0
  188. deprecated/FrmEntryMetaDeprecated.php +3 -0
  189. deprecated/FrmFieldDeprecated.php +3 -0
  190. deprecated/FrmFormDeprecated.php +3 -0
  191. deprecated/FrmPointers.php +3 -0
  192. formidable.php +1 -1
  193. js/bootstrap-multiselect.js +592 -207
  194. js/formidable.js +17 -0
  195. js/formidable.min.js +9 -8
  196. js/formidable_admin.js +80 -20
  197. languages/formidable.pot +1024 -1012
  198. readme.txt +63 -59
classes/controllers/FrmAddonsController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmAddonsController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmAddonsController {
7
 
classes/controllers/FrmAppController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmAppController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmAppController {
7
 
classes/controllers/FrmEntriesController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmEntriesController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmEntriesController {
7
 
classes/controllers/FrmFieldsController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFieldsController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFieldsController {
7
 
classes/controllers/FrmFormActionsController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFormActionsController {
4
  public static $action_post_type = 'frm_form_actions';
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFormActionsController {
7
  public static $action_post_type = 'frm_form_actions';
classes/controllers/FrmFormsController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFormsController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFormsController {
7
 
classes/controllers/FrmHooksController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmHooksController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmHooksController {
7
 
classes/controllers/FrmInboxController.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * @since 4.05
4
  */
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * @since 4.05
8
  */
classes/controllers/FrmSMTPController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * SMTP Sub-page.
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * SMTP Sub-page.
classes/controllers/FrmSettingsController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmSettingsController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmSettingsController {
7
 
classes/controllers/FrmSimpleBlocksController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmSimpleBlocksController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmSimpleBlocksController {
7
 
classes/controllers/FrmStylesController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmStylesController {
4
  public static $post_type = 'frm_styles';
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmStylesController {
7
  public static $post_type = 'frm_styles';
classes/controllers/FrmXMLController.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmXMLController {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmXMLController {
7
 
classes/factories/FrmEntryFactory.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/factories/FrmFieldFactory.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.03.05
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.03.05
classes/helpers/FrmAppHelper.php CHANGED
@@ -11,7 +11,7 @@ class FrmAppHelper {
11
  /**
12
  * @since 2.0
13
  */
14
- public static $plug_version = '4.07';
15
 
16
  /**
17
  * @since 1.07.02
@@ -2648,6 +2648,13 @@ class FrmAppHelper {
2648
  return $locales;
2649
  }
2650
 
 
 
 
 
 
 
 
2651
  /**
2652
  * Use the WP 4.7 wp_doing_ajax function
2653
  *
11
  /**
12
  * @since 2.0
13
  */
14
+ public static $plug_version = '4.07.01';
15
 
16
  /**
17
  * @since 1.07.02
2648
  return $locales;
2649
  }
2650
 
2651
+ /**
2652
+ * Output HTML containing reference text for accessibility
2653
+ */
2654
+ public static function multiselect_accessibility() {
2655
+ include_once self::plugin_path() . '/classes/views/frm-forms/multiselect-accessibility.php';
2656
+ }
2657
+
2658
  /**
2659
  * Use the WP 4.7 wp_doing_ajax function
2660
  *
classes/helpers/FrmCSVExportHelper.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmCSVExportHelper {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmCSVExportHelper {
7
 
classes/helpers/FrmEmailHelper.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.03.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.03.04
classes/helpers/FrmEntriesListHelper.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmEntriesListHelper extends FrmListHelper {
4
  protected $column_name;
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmEntriesListHelper extends FrmListHelper {
7
  protected $column_name;
classes/helpers/FrmShortcodeHelper.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * @since 2.02.12
4
  */
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * @since 2.02.12
8
  */
classes/helpers/FrmStylesHelper.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmStylesHelper {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmStylesHelper {
7
 
classes/helpers/FrmTipsHelper.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmTipsHelper {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmTipsHelper {
7
 
classes/helpers/FrmXMLHelper.php CHANGED
@@ -358,7 +358,8 @@ class FrmXMLHelper {
358
  * TODO: Cut down on params
359
  */
360
  private static function import_xml_fields( $xml_fields, $form_id, $this_form, &$form_fields, &$imported ) {
361
- $in_section = 0;
 
362
 
363
  foreach ( $xml_fields as $field ) {
364
  $f = self::fill_field( $field, $form_id );
@@ -383,6 +384,8 @@ class FrmXMLHelper {
383
  unset( $form_fields[ $f['field_key'] ] );
384
  }
385
  } elseif ( isset( $form_fields[ $f['field_key'] ] ) ) {
 
 
386
  // check for field to edit by field key
387
  unset( $f['id'] );
388
 
@@ -400,6 +403,10 @@ class FrmXMLHelper {
400
  self::create_imported_field( $f, $imported );
401
  }
402
  }
 
 
 
 
403
  }
404
 
405
  private static function fill_field( $field, $form_id ) {
@@ -614,6 +621,46 @@ class FrmXMLHelper {
614
  }
615
  }
616
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
617
  /**
618
  * Updates the custom style setting on import
619
  * Convert the post slug to an ID
358
  * TODO: Cut down on params
359
  */
360
  private static function import_xml_fields( $xml_fields, $form_id, $this_form, &$form_fields, &$imported ) {
361
+ $in_section = 0;
362
+ $keys_by_original_field_id = array();
363
 
364
  foreach ( $xml_fields as $field ) {
365
  $f = self::fill_field( $field, $form_id );
384
  unset( $form_fields[ $f['field_key'] ] );
385
  }
386
  } elseif ( isset( $form_fields[ $f['field_key'] ] ) ) {
387
+ $keys_by_original_field_id[ $f['id'] ] = $f['field_key'];
388
+
389
  // check for field to edit by field key
390
  unset( $f['id'] );
391
 
403
  self::create_imported_field( $f, $imported );
404
  }
405
  }
406
+
407
+ if ( $keys_by_original_field_id ) {
408
+ self::maybe_update_field_ids( $form_id, $keys_by_original_field_id );
409
+ }
410
  }
411
 
412
  private static function fill_field( $field, $form_id ) {
621
  }
622
  }
623
 
624
+ /**
625
+ * Fix field ids for fields that already exist prior to import.
626
+ *
627
+ * @since 4.07
628
+ * @param int $form_id
629
+ * @param array $keys_by_original_field_id
630
+ */
631
+ protected static function maybe_update_field_ids( $form_id, $keys_by_original_field_id ) {
632
+ global $frm_duplicate_ids;
633
+
634
+ $former_duplicate_ids = $frm_duplicate_ids;
635
+ $where = array(
636
+ array(
637
+ 'or' => 1,
638
+ 'fi.form_id' => $form_id,
639
+ 'fr.parent_form_id' => $form_id,
640
+ ),
641
+ );
642
+ $fields = FrmField::getAll( $where, 'field_order' );
643
+ $field_id_by_key = wp_list_pluck( $fields, 'id', 'field_key' );
644
+
645
+ foreach ( $fields as $field ) {
646
+ $before = (array) clone $field;
647
+ $field = (array) $field;
648
+ $frm_duplicate_ids = $keys_by_original_field_id;
649
+ $after = FrmFieldsHelper::switch_field_ids( $field );
650
+
651
+ if ( $before['field_options'] !== $after['field_options'] ) {
652
+ $frm_duplicate_ids = $field_id_by_key;
653
+ $after = FrmFieldsHelper::switch_field_ids( $after );
654
+
655
+ if ( $before['field_options'] !== $after['field_options'] ) {
656
+ FrmField::update( $field['id'], array( 'field_options' => $after['field_options'] ) );
657
+ }
658
+ }
659
+ }
660
+
661
+ $frm_duplicate_ids = $former_duplicate_ids;
662
+ }
663
+
664
  /**
665
  * Updates the custom style setting on import
666
  * Convert the post slug to an ID
classes/models/FrmAddon.php CHANGED
@@ -1,5 +1,4 @@
1
  <?php
2
-
3
  if ( ! defined( 'ABSPATH' ) ) {
4
  die( 'You are not allowed to call this page directly.' );
5
  }
1
  <?php
 
2
  if ( ! defined( 'ABSPATH' ) ) {
3
  die( 'You are not allowed to call this page directly.' );
4
  }
classes/models/FrmCreateFile.php CHANGED
@@ -1,5 +1,4 @@
1
  <?php
2
-
3
  if ( ! defined( 'ABSPATH' ) ) {
4
  die( 'You are not allowed to call this page directly.' );
5
  }
1
  <?php
 
2
  if ( ! defined( 'ABSPATH' ) ) {
3
  die( 'You are not allowed to call this page directly.' );
4
  }
classes/models/FrmDb.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmDb {
4
  public $fields;
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmDb {
7
  public $fields;
classes/models/FrmEmail.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.03.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.03.04
classes/models/FrmEntryFormatter.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/models/FrmEntryShortcodeFormatter.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/models/FrmEntryValidate.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmEntryValidate {
4
  public static function validate( $values, $exclude = false ) {
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmEntryValidate {
7
  public static function validate( $values, $exclude = false ) {
classes/models/FrmEntryValues.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/models/FrmFieldFormHtml.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * @since 3.0
4
  */
@@ -359,9 +363,7 @@ class FrmFieldFormHtml {
359
  unset( $shortcode_atts['class'] );
360
  }
361
 
362
- if ( isset( $this->pass_args['errors'][ 'field' . $this->field_id ] ) ) {
363
- $shortcode_atts['aria-invalid'] = 'true';
364
- }
365
 
366
  $this->field_obj->set_field_column( 'shortcodes', $shortcode_atts );
367
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * @since 3.0
8
  */
363
  unset( $shortcode_atts['class'] );
364
  }
365
 
366
+ $shortcode_atts['aria-invalid'] = isset( $this->pass_args['errors'][ 'field' . $this->field_id ] ) ? 'true' : 'false';
 
 
367
 
368
  $this->field_obj->set_field_column( 'shortcodes', $shortcode_atts );
369
 
classes/models/FrmFieldOption.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.03.05
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.03.05
classes/models/FrmFieldValue.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/models/FrmFieldValueSelector.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * A class for the field value selector
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * A class for the field value selector
classes/models/FrmFormAction.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFormAction {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFormAction {
7
 
classes/models/FrmFormApi.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFormApi {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFormApi {
7
 
classes/models/FrmFormMigrator.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  abstract class FrmFormMigrator {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  abstract class FrmFormMigrator {
7
 
classes/models/FrmFormTemplateApi.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmFormTemplateApi extends FrmFormApi {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmFormTemplateApi extends FrmFormApi {
7
 
classes/models/FrmInbox.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * @since 4.05
4
  */
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * @since 4.05
8
  */
classes/models/FrmInstallPlugin.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 4.04.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 4.04.04
classes/models/FrmMigrate.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmMigrate {
4
  public $fields;
@@ -7,10 +10,6 @@ class FrmMigrate {
7
  public $entry_metas;
8
 
9
  public function __construct() {
10
- if ( ! defined( 'ABSPATH' ) ) {
11
- die( 'You are not allowed to call this page directly.' );
12
- }
13
-
14
  global $wpdb;
15
  $this->fields = $wpdb->prefix . 'frm_fields';
16
  $this->forms = $wpdb->prefix . 'frm_forms';
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmMigrate {
7
  public $fields;
10
  public $entry_metas;
11
 
12
  public function __construct() {
 
 
 
 
13
  global $wpdb;
14
  $this->fields = $wpdb->prefix . 'frm_fields';
15
  $this->forms = $wpdb->prefix . 'frm_forms';
classes/models/FrmNotification.php CHANGED
@@ -1,11 +1,10 @@
1
  <?php
 
 
 
2
 
3
  class FrmNotification {
4
  public function __construct() {
5
- if ( ! defined( 'ABSPATH' ) ) {
6
- die( 'You are not allowed to call this page directly.' );
7
- }
8
-
9
  self::hook_emails_to_action();
10
  }
11
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmNotification {
7
  public function __construct() {
 
 
 
 
8
  self::hook_emails_to_action();
9
  }
10
 
classes/models/FrmPersonalData.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmPersonalData {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmPersonalData {
7
 
classes/models/FrmReviews.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmReviews {
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmReviews {
7
 
classes/models/FrmSettings.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmSettings {
4
  public $option_name = 'frm_options';
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmSettings {
7
  public $option_name = 'frm_options';
classes/models/FrmStyle.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmStyle {
4
  public $number = false; // Unique ID number of the current instance.
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmStyle {
7
  public $number = false; // Unique ID number of the current instance.
classes/models/FrmTableHTMLGenerator.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 2.04
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 2.04
classes/models/FrmUsage.php CHANGED
@@ -234,6 +234,7 @@ class FrmUsage {
234
  'draft_msg',
235
  'submit_align',
236
  'protect_files',
 
237
  'max_entries',
238
  'open_status',
239
  'closed_msg',
234
  'draft_msg',
235
  'submit_align',
236
  'protect_files',
237
+ 'protect_files_role',
238
  'max_entries',
239
  'open_status',
240
  'closed_msg',
classes/models/fields/FrmFieldCaptcha.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldCheckbox.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldDefault.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldEmail.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldHTML.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldHidden.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldNumber.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldPhone.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldRadio.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldSelect.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldText.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldTextarea.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldType.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldUrl.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/models/fields/FrmFieldUserID.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  /**
4
  * @since 3.0
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  /**
7
  * @since 3.0
classes/views/addons/list.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm_wrap" id="frm-addons-page">
2
  <?php
3
  FrmAppHelper::get_admin_header(
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm_wrap" id="frm-addons-page">
7
  <?php
8
  FrmAppHelper::get_admin_header(
classes/views/addons/settings.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="wrap">
2
  <?php
3
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="wrap">
7
  <?php
8
 
classes/views/addons/upgrade_to_pro.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm_wrap wrap upgrade_to_pro frm-fields">
2
  <h1 class="frm_pro_heading">
3
  <img src="<?php echo esc_url( FrmAppHelper::plugin_url() ); ?>/images/logo.png" alt="Upgrade to Pro" />
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm_wrap wrap upgrade_to_pro frm-fields">
7
  <h1 class="frm_pro_heading">
8
  <img src="<?php echo esc_url( FrmAppHelper::plugin_url() ); ?>/images/logo.png" alt="Upgrade to Pro" />
classes/views/frm-entries/_sidebar-shared-pub.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  if ( ! isset( $entry ) ) {
3
  $entry = $record;
4
  } ?>
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  if ( ! isset( $entry ) ) {
7
  $entry = $record;
8
  } ?>
classes/views/frm-entries/direct.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <!DOCTYPE html>
2
  <html <?php language_attributes(); ?>>
3
  <head>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <!DOCTYPE html>
7
  <html <?php language_attributes(); ?>>
8
  <head>
classes/views/frm-entries/errors.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  if ( isset( $include_extra_container ) ) { ?>
3
  <div class="<?php echo esc_attr( $include_extra_container ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container">
4
  <?php
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  if ( isset( $include_extra_container ) ) { ?>
7
  <div class="<?php echo esc_attr( $include_extra_container ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container">
8
  <?php
classes/views/frm-entries/form.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  if ( empty( $values ) || ! isset( $values['fields'] ) || empty( $values['fields'] ) ) { ?>
3
  <div class="frm_forms <?php echo esc_attr( FrmFormsHelper::get_form_style_class( $form ) ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container">
4
  <div class="frm_error_style">
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  if ( empty( $values ) || ! isset( $values['fields'] ) || empty( $values['fields'] ) ) { ?>
7
  <div class="frm_forms <?php echo esc_attr( FrmFormsHelper::get_form_style_class( $form ) ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container">
8
  <div class="frm_error_style">
classes/views/frm-entries/list.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div id="form_entries_page" class="frm_wrap frm_list_entry_page">
2
  <?php if ( $form ) { ?>
3
  <div class="frm_page_container">
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div id="form_entries_page" class="frm_wrap frm_list_entry_page">
7
  <?php if ( $form ) { ?>
8
  <div class="frm_page_container">
classes/views/frm-entries/new.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm_forms <?php echo esc_attr( FrmFormsHelper::get_form_style_class( $values ) ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container" <?php echo wp_strip_all_tags( apply_filters( 'frm_form_div_attributes', '', $form ) ); // WPCS: XSS ok. ?>>
2
  <?php if ( ! isset( $include_form_tag ) || $include_form_tag ) { ?>
3
  <form enctype="<?php echo esc_attr( apply_filters( 'frm_form_enctype', 'multipart/form-data', $form ) ); ?>" method="post" class="frm-show-form <?php do_action( 'frm_form_classes', $form ); ?>" id="form_<?php echo esc_attr( $form->form_key ); ?>" <?php echo $frm_settings->use_html ? '' : 'action=""'; ?> <?php echo wp_strip_all_tags( apply_filters( 'frm_form_attributes', '', $form ) ); // WPCS: XSS ok. ?>>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm_forms <?php echo esc_attr( FrmFormsHelper::get_form_style_class( $values ) ); ?>" id="frm_form_<?php echo esc_attr( $form->id ); ?>_container" <?php echo wp_strip_all_tags( apply_filters( 'frm_form_div_attributes', '', $form ) ); // WPCS: XSS ok. ?>>
7
  <?php if ( ! isset( $include_form_tag ) || $include_form_tag ) { ?>
8
  <form enctype="<?php echo esc_attr( apply_filters( 'frm_form_enctype', 'multipart/form-data', $form ) ); ?>" method="post" class="frm-show-form <?php do_action( 'frm_form_classes', $form ); ?>" id="form_<?php echo esc_attr( $form->form_key ); ?>" <?php echo $frm_settings->use_html ? '' : 'action=""'; ?> <?php echo wp_strip_all_tags( apply_filters( 'frm_form_attributes', '', $form ) ); // WPCS: XSS ok. ?>>
classes/views/frm-entries/no_entries.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frmcenter frm_no_entries_form">
2
  <?php if ( $form && isset( $form->options['no_save'] ) && $form->options['no_save'] ) { ?>
3
  <h3><?php esc_html_e( 'This form is not set to save any entries.', 'formidable' ); ?></h3>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frmcenter frm_no_entries_form">
7
  <?php if ( $form && isset( $form->options['no_save'] ) && $form->options['no_save'] ) { ?>
8
  <h3><?php esc_html_e( 'This form is not set to save any entries.', 'formidable' ); ?></h3>
classes/views/frm-entries/show.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div id="form_show_entry_page" class="frm_wrap frm_single_entry_page">
2
  <div class="frm_page_container">
3
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div id="form_show_entry_page" class="frm_wrap frm_single_entry_page">
7
  <div class="frm_page_container">
8
 
classes/views/frm-entries/sidebar-shared.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm_with_icons frm_no_print">
2
  <h3>
3
  <?php esc_html_e( 'Entry Actions', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm_with_icons frm_no_print">
7
  <h3>
8
  <?php esc_html_e( 'Entry Actions', 'formidable' ); ?>
classes/views/frm-entries/sidebar-show.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  _deprecated_file( esc_html( basename( __FILE__ ) ), '4.0' );
3
 
4
  do_action( 'frm_show_entry_sidebar', $entry );
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  _deprecated_file( esc_html( basename( __FILE__ ) ), '4.0' );
7
 
8
  do_action( 'frm_show_entry_sidebar', $entry );
classes/views/frm-fields/back-end/ajax-field-placeholder.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <li id="frm_field_id_<?php echo esc_attr( $field_object->id ); ?>" class="<?php echo esc_attr( $li_classes ); ?> frm_field_loading" data-fid="<?php echo esc_attr( $field_object->id ); ?>" data-formid="<?php echo esc_attr( 'divider' == $field_object->type ? FrmField::get_option( $field_object, 'form_select' ) : $field_object->form_id ); ?>" data-ftype="<?php echo esc_attr( $display['type'] ); ?>">
2
  <span class="frm-wait frm_visible_spinner"></span>
3
  <span class="frm_hidden_fdata frm_hidden"><?php echo htmlspecialchars( json_encode( $field_object ) ); // WPCS: XSS ok. ?></span>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <li id="frm_field_id_<?php echo esc_attr( $field_object->id ); ?>" class="<?php echo esc_attr( $li_classes ); ?> frm_field_loading" data-fid="<?php echo esc_attr( $field_object->id ); ?>" data-formid="<?php echo esc_attr( 'divider' == $field_object->type ? FrmField::get_option( $field_object, 'form_select' ) : $field_object->form_id ); ?>" data-ftype="<?php echo esc_attr( $display['type'] ); ?>">
7
  <span class="frm-wait frm_visible_spinner"></span>
8
  <span class="frm_hidden_fdata frm_hidden"><?php echo htmlspecialchars( json_encode( $field_object ) ); // WPCS: XSS ok. ?></span>
classes/views/frm-fields/back-end/automatic-width.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm6 frm_form_field frm_multiple_cont_<?php echo absint( $field['id'] ); ?>">
2
  <label for="size_<?php echo esc_attr( $field['id'] ); ?>">
3
  <input type="checkbox" name="field_options[size_<?php echo esc_attr( $field['id'] ); ?>]" id="size_<?php echo esc_attr( $field['id'] ); ?>" value="1" <?php echo FrmField::is_option_true( $field, 'size' ) ? 'checked="checked"' : ''; ?> />
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm6 frm_form_field frm_multiple_cont_<?php echo absint( $field['id'] ); ?>">
7
  <label for="size_<?php echo esc_attr( $field['id'] ); ?>">
8
  <input type="checkbox" name="field_options[size_<?php echo esc_attr( $field['id'] ); ?>]" id="size_<?php echo esc_attr( $field['id'] ); ?>" value="1" <?php echo FrmField::is_option_true( $field, 'size' ) ? 'checked="checked"' : ''; ?> />
classes/views/frm-fields/back-end/bulk-options-overlay.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
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' ) ) ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div id="frm-bulk-modal" class="frm_hidden settings-lite-cta">
7
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
8
  <?php FrmAppHelper::icon_by_class( 'frmfont frm_close_icon', array( 'aria-label' => __( 'Close', 'formidable' ) ) ); ?>
classes/views/frm-fields/back-end/dropdown-field.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  if ( isset( $field['post_field'] ) && 'post_category' === $field['post_field'] && FrmAppHelper::pro_is_installed() ) {
4
  echo FrmProPost::get_category_dropdown( // WPCS: XSS ok.
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  if ( isset( $field['post_field'] ) && 'post_category' === $field['post_field'] && FrmAppHelper::pro_is_installed() ) {
7
  echo FrmProPost::get_category_dropdown( // WPCS: XSS ok.
classes/views/frm-fields/back-end/field-captcha.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  $frm_settings = FrmAppHelper::get_settings();
3
  if ( empty( $frm_settings->pubkey ) ) {
4
  ?>
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  $frm_settings = FrmAppHelper::get_settings();
7
  if ( empty( $frm_settings->pubkey ) ) {
8
  ?>
classes/views/frm-fields/back-end/field-choices.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  if ( isset( $args['field']['post_field'] ) && $args['field']['post_field'] == 'post_category' ) {
3
  ?>
4
  <div class="frm-inline-message" id="frm_has_hidden_options_<?php echo esc_attr( $args['field']['id'] ); ?>">
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  if ( isset( $args['field']['post_field'] ) && $args['field']['post_field'] == 'post_category' ) {
7
  ?>
8
  <div class="frm-inline-message" id="frm_has_hidden_options_<?php echo esc_attr( $args['field']['id'] ); ?>">
classes/views/frm-fields/back-end/field-description.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p>
2
  <label for="frm_description_<?php echo esc_attr( $field['id'] ); ?>">
3
  <?php esc_html_e( 'Field Description', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p>
7
  <label for="frm_description_<?php echo esc_attr( $field['id'] ); ?>">
8
  <?php esc_html_e( 'Field Description', 'formidable' ); ?>
classes/views/frm-fields/back-end/field-hidden.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <input type="text" id="<?php echo esc_attr( $html_id ); ?>" name="<?php echo esc_attr( $field_name ); ?>" value="<?php echo esc_attr( $field['default_value'] ); ?>" class="dyn_default_value" />
2
  <p class="howto frm_clear">
3
  <?php esc_html_e( 'Note: This field will not show in the form. Enter the value to be hidden.', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <input type="text" id="<?php echo esc_attr( $html_id ); ?>" name="<?php echo esc_attr( $field_name ); ?>" value="<?php echo esc_attr( $field['default_value'] ); ?>" class="dyn_default_value" />
7
  <p class="howto frm_clear">
8
  <?php esc_html_e( 'Note: This field will not show in the form. Enter the value to be hidden.', 'formidable' ); ?>
classes/views/frm-fields/back-end/field-html.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm-embed-field-placeholder">
2
  <div class="frm-embed-message">
3
  <?php esc_html_e( 'Custom HTML:', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm-embed-field-placeholder">
7
  <div class="frm-embed-message">
8
  <?php esc_html_e( 'Custom HTML:', 'formidable' ); ?>
classes/views/frm-fields/back-end/field-multiple.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  _deprecated_file( esc_html( basename( __FILE__ ) ), '4.0', null );
4
 
@@ -7,5 +10,5 @@ if ( isset( $field['post_field'] ) && $field['post_field'] == 'post_category' )
7
  do_action( 'frm_after_checkbox', compact( 'field', 'field_name', 'type' ) );
8
  } else {
9
  $read_only = $field['read_only'];
10
- include( dirname( __FILE__ ) . '/' . $field['type'] . '-field.php' );
11
  }
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  _deprecated_file( esc_html( basename( __FILE__ ) ), '4.0', null );
7
 
10
  do_action( 'frm_after_checkbox', compact( 'field', 'field_name', 'type' ) );
11
  } else {
12
  $read_only = $field['read_only'];
13
+ include dirname( __FILE__ ) . '/' . $field['type'] . '-field.php';
14
  }
classes/views/frm-fields/back-end/field-options.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <span class="frm-bulk-edit-link <?php echo empty( FrmField::get_option( $args['field'], 'image_options' ) ) ? '' : 'frm_hidden'; ?> ">
2
  <a href="#" title="<?php echo esc_attr( $option_title ); ?>" class="frm-bulk-edit-link">
3
  <?php echo esc_html( $this->get_bulk_edit_string() ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <span class="frm-bulk-edit-link <?php echo empty( FrmField::get_option( $args['field'], 'image_options' ) ) ? '' : 'frm_hidden'; ?> ">
7
  <a href="#" title="<?php echo esc_attr( $option_title ); ?>" class="frm-bulk-edit-link">
8
  <?php echo esc_html( $this->get_bulk_edit_string() ); ?>
classes/views/frm-fields/back-end/field-user-id.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
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 />
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <span class="frm-with-left-icon">
7
  <?php FrmAppHelper::icon_by_class( 'frmfont frm_user_icon', array( 'aria-hidden' => 'true' ) ); ?>
8
  <input type="text" value="<?php esc_attr_e( 'User ID fields will not show in your form.', 'formidable' ); ?>" disabled />
classes/views/frm-fields/back-end/html-content.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm-has-modal">
2
  <label>
3
  <?php esc_html_e( 'Content', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm-has-modal">
7
  <label>
8
  <?php esc_html_e( 'Content', 'formidable' ); ?>
classes/views/frm-fields/back-end/inline-modal.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
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' ) ) ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm-inline-modal postbox <?php echo esc_attr( $args['class'] . ( $args['show'] ? '' : ' frm_hidden' ) ); ?>" id="<?php echo esc_attr( $args['id'] ); ?>">
7
  <a href="#" class="dismiss alignright" title="<?php esc_attr_e( 'Close', 'formidable' ); ?>">
8
  <?php FrmAppHelper::icon_by_class( 'frmfont frm_close_icon', array( 'aria-label' => __( 'Close', 'formidable' ) ) ); ?>
classes/views/frm-fields/back-end/input-mask-info.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="howto">
2
  <?php esc_html_e( 'To create a custom input mask, you’ll need to use this specific set of symbols:', 'formidable' ); ?>
3
  </p>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="howto">
7
  <?php esc_html_e( 'To create a custom input mask, you’ll need to use this specific set of symbols:', 'formidable' ); ?>
8
  </p>
classes/views/frm-fields/back-end/layout-classes.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div id="frm-layout-classes">
2
  <p class="howto">
3
  <?php esc_html_e( 'Click on any box below to set the width for your selected field.', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div id="frm-layout-classes">
7
  <p class="howto">
8
  <?php esc_html_e( 'Click on any box below to set the width for your selected field.', 'formidable' ); ?>
classes/views/frm-fields/back-end/max.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm6 frm_form_field">
2
  <label for="field_options_max_<?php echo esc_attr( $field['id'] ); ?>">
3
  <?php
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm6 frm_form_field">
7
  <label for="field_options_max_<?php echo esc_attr( $field['id'] ); ?>">
8
  <?php
classes/views/frm-fields/back-end/number-range.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm8 frm_first frm_form_field frm-number-range">
2
  <label for="frm_format_<?php echo esc_attr( $field['field_key'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Set the number range the field validation should allow. Browsers that support the HTML5 number field require a number range to determine the numbers seen when clicking the arrows next to the field.', 'formidable' ); ?>">
3
  <?php esc_html_e( 'Number Range', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm8 frm_first frm_form_field frm-number-range">
7
  <label for="frm_format_<?php echo esc_attr( $field['field_key'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Set the number range the field validation should allow. Browsers that support the HTML5 number field require a number range to determine the numbers seen when clicking the arrows next to the field.', 'formidable' ); ?>">
8
  <?php esc_html_e( 'Number Range', 'formidable' ); ?>
classes/views/frm-fields/back-end/pixels-wide.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="<?php echo esc_attr( $display_max ? 'frm6 frm_form_field' : '' ); ?>">
2
  <label for="field_options_size_<?php echo esc_attr( $field['id'] ); ?>">
3
  <?php esc_html_e( 'Field Size', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="<?php echo esc_attr( $display_max ? 'frm6 frm_form_field' : '' ); ?>">
7
  <label for="field_options_size_<?php echo esc_attr( $field['id'] ); ?>">
8
  <?php esc_html_e( 'Field Size', 'formidable' ); ?>
classes/views/frm-fields/back-end/radio-field.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  if ( isset( $field['post_field'] ) && $field['post_field'] === 'post_category' ) {
4
  $type = $field['type'];
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  if ( isset( $field['post_field'] ) && $field['post_field'] === 'post_category' ) {
7
  $type = $field['type'];
classes/views/frm-fields/back-end/radio-images.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm6 frm_form_field frm_noallow frm_show_upgrade" data-upgrade="<?php esc_attr_e( 'Separate Values', 'formidable' ); ?>" data-message="<?php esc_attr_e( 'Add a separate value to use for calculations, email routing, saving to the database, and many other uses. The option values are saved while the option labels are shown in the form.', 'formidable' ); ?>" data-medium="builder" data-content="separate-values">
2
  <label>
3
  <input type="checkbox" value="1" disabled="disabled" />
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm6 frm_form_field frm_noallow frm_show_upgrade" data-upgrade="<?php esc_attr_e( 'Separate Values', 'formidable' ); ?>" data-message="<?php esc_attr_e( 'Add a separate value to use for calculations, email routing, saving to the database, and many other uses. The option values are saved while the option labels are shown in the form.', 'formidable' ); ?>" data-medium="builder" data-content="separate-values">
7
  <label>
8
  <input type="checkbox" value="1" disabled="disabled" />
classes/views/frm-fields/back-end/settings.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="frm-single-settings frm_hidden frm-fields frm-type-<?php echo esc_attr( $field['type'] ); ?>" id="frm-single-settings-<?php echo esc_attr( $field['id'] ); ?>" data-fid="<?php echo esc_attr( $field['id'] ); ?>">
2
  <input type="hidden" name="frm_fields_submitted[]" value="<?php echo esc_attr( $field['id'] ); ?>" />
3
  <input type="hidden" name="field_options[field_order_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['field_order'] ); ?>"/>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="frm-single-settings frm_hidden frm-fields frm-type-<?php echo esc_attr( $field['type'] ); ?>" id="frm-single-settings-<?php echo esc_attr( $field['id'] ); ?>" data-fid="<?php echo esc_attr( $field['id'] ); ?>">
7
  <input type="hidden" name="frm_fields_submitted[]" value="<?php echo esc_attr( $field['id'] ); ?>" />
8
  <input type="hidden" name="field_options[field_order_<?php echo esc_attr( $field['id'] ); ?>]" value="<?php echo esc_attr( $field['field_order'] ); ?>"/>
classes/views/frm-fields/back-end/smart-values.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <div class="cta-inside">
2
  <p>
3
  <?php
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <div class="cta-inside">
7
  <p>
8
  <?php
classes/views/frm-fields/back-end/value-format.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <p class="frm-has-modal">
2
  <label for="frm_format_<?php echo esc_attr( $field['field_key'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Insert the format you would like to accept. Use a regular expression starting with ^ or an exact format like (999)999-9999.', 'formidable' ); ?>">
3
  <?php esc_html_e( 'Format', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <p class="frm-has-modal">
7
  <label for="frm_format_<?php echo esc_attr( $field['field_key'] ); ?>" class="frm_help" title="<?php esc_attr_e( 'Insert the format you would like to accept. Use a regular expression starting with ^ or an exact format like (999)999-9999.', 'formidable' ); ?>">
8
  <?php esc_html_e( 'Format', 'formidable' ); ?>
classes/views/frm-fields/front-end/checkbox-field.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * Show the checkbox field on the front-end.
4
  * Extra line breaks show as space on the front-end when
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * Show the checkbox field on the front-end.
8
  * Extra line breaks show as space on the front-end when
classes/views/frm-fields/front-end/dropdown-field.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  if ( isset( $field['post_field'] ) && $field['post_field'] == 'post_category' && FrmAppHelper::pro_is_installed() ) {
4
  echo FrmProPost::get_category_dropdown( // WPCS: XSS ok.
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  if ( isset( $field['post_field'] ) && $field['post_field'] == 'post_category' && FrmAppHelper::pro_is_installed() ) {
7
  echo FrmProPost::get_category_dropdown( // WPCS: XSS ok.
classes/views/frm-fields/front-end/radio-field.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  /**
3
  * Show the radio field on the front-end.
4
  * Extra line breaks show as space on the front-end when
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  /**
7
  * Show the radio field on the front-end.
8
  * Extra line breaks show as space on the front-end when
classes/views/frm-fields/input.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldType::field_input' );
3
 
4
  $field_obj = FrmFieldFactory::get_field_type( $field['type'], $field );
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldType::field_input' );
7
 
8
  $field_obj = FrmFieldFactory::get_field_type( $field['type'], $field );
classes/views/frm-fields/radio.php CHANGED
@@ -1,3 +1,7 @@
1
  <?php
 
 
 
 
2
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldsHelper::show_single_option' );
3
  FrmFieldsHelper::show_single_option( $field );
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldsHelper::show_single_option' );
7
  FrmFieldsHelper::show_single_option( $field );
classes/views/frm-fields/show-build.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldType::show_on_form_builder' );
4
 
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  _deprecated_file( esc_html( basename( __FILE__ ) ), '3.0', null, 'FrmFieldType::show_on_form_builder' );
7
 
classes/views/frm-fields/single-option.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
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 ); ?>"/>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <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' : ''; ?>">
7
  <?php FrmAppHelper::icon_by_class( 'frmfont frm_drag_icon frm-drag' ); ?>
8
  <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 ); ?>"/>
classes/views/frm-form-actions/_action_icon.php CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  <li class="frm-action <?php echo esc_attr( $group_class . ( isset( $data['data-upgrade'] ) ? ' frm-not-installed' : '' ) ); ?>">
2
  <a href="javascript:void(0)" class="<?php echo esc_attr( $classes ); ?>"
3
  data-limit="<?php echo esc_attr( $action_control->action_options['limit'] ); ?>"
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
  <li class="frm-action <?php echo esc_attr( $group_class . ( isset( $data['data-upgrade'] ) ? ' frm-not-installed' : '' ) ); ?>">
7
  <a href="javascript:void(0)" class="<?php echo esc_attr( $classes ); ?>"
8
  data-limit="<?php echo esc_attr( $action_control->action_options['limit'] ); ?>"
classes/views/frm-form-actions/_action_inside.php CHANGED
@@ -1,3 +1,9 @@
 
 
 
 
 
 
1
  <input type="hidden" name="<?php echo esc_attr( $action_control->get_field_name( 'post_excerpt', '' ) ); ?>" class="frm_action_name" value="<?php echo esc_attr( $form_action->post_excerpt ); ?>" />
2
  <input type="hidden" name="<?php echo esc_attr( $action_control->get_field_name( 'ID', '' ) ); ?>" value="<?php echo esc_attr( $form_action->ID ); ?>" />
3
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
+
7
  <input type="hidden" name="<?php echo esc_attr( $action_control->get_field_name( 'post_excerpt', '' ) ); ?>" class="frm_action_name" value="<?php echo esc_attr( $form_action->post_excerpt ); ?>" />
8
  <input type="hidden" name="<?php echo esc_attr( $action_control->get_field_name( 'ID', '' ) ); ?>" value="<?php echo esc_attr( $form_action->ID ); ?>" />
9
 
classes/views/frm-form-actions/_email_settings.php CHANGED
@@ -1,3 +1,9 @@
 
 
 
 
 
 
1
  <p class="frm_has_shortcodes frm_to_row frm_email_row">
2
  <label for="<?php echo esc_attr( $this->get_field_id( 'email_to' ) ); ?>" <?php FrmAppHelper::maybe_add_tooltip( 'email_to' ); ?>>
3
  <?php esc_html_e( 'To', 'formidable' ); ?>
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+ ?>
6
+
7
  <p class="frm_has_shortcodes frm_to_row frm_email_row">
8
  <label for="<?php echo esc_attr( $this->get_field_id( 'email_to' ) ); ?>" <?php FrmAppHelper::maybe_add_tooltip( 'email_to' ); ?>>
9
  <?php esc_html_e( 'To', 'formidable' ); ?>
classes/views/frm-form-actions/default_actions.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  // add post action
3
  class FrmDefPostAction extends FrmFormAction {
4
  public function __construct() {
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  // add post action
7
  class FrmDefPostAction extends FrmFormAction {
8
  public function __construct() {
classes/views/frm-form-actions/email_action.php CHANGED
@@ -1,4 +1,7 @@
1
  <?php
 
 
 
2
 
3
  class FrmEmailAction extends FrmFormAction {
4
 
@@ -19,7 +22,7 @@ class FrmEmailAction extends FrmFormAction {
19
  public function form( $form_action, $args = array() ) {
20
  extract( $args );
21
 
22
- include( FrmAppHelper::plugin_path() . '/classes/views/frm-form-actions/_email_settings.php' );
23
  }
24
 
25
  public function get_defaults() {
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
 
6
  class FrmEmailAction extends FrmFormAction {
7
 
22
  public function form( $form_action, $args = array() ) {
23
  extract( $args );
24
 
25
+ include FrmAppHelper::plugin_path() . '/classes/views/frm-form-actions/_email_settings.php';
26
  }
27
 
28
  public function get_defaults() {
classes/views/frm-form-actions/form_action.php CHANGED
@@ -1,4 +1,8 @@
1
  <?php
 
 
 
 
2
  $a = FrmAppHelper::simple_get( 't', 'sanitize_title', 'advanced_settings' );
3
 
4
  $form_action = apply_filters( 'frm_form_action_settings', $form_action, $form_action->post_excerpt );
1
  <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4
+ }
5
+
6
  $a = FrmAppHelper::simple_get( 't', 'sanitize_title', 'advanced_settings' );
7
 
8
  $form_action = apply_filters( 'frm_form_action_settings', $form_action, $form_action->post_excerpt );
classes/views/frm-form-actions/settings.php CHANGED
@@ -1,7 +1,12 @@
 
 
 
 
 
1
  <p class="howto">
2
  <?php esc_html_e( 'Add form actions to your form to perform tasks when an entry is created, updated, imported, and more.', 'formidable' ); ?>
3
  </p>
4
-
5
  <div id="frm_email_addon_menu" class="frm-limited-actions">
6
  <?php
7
  FrmAppHelper::show_search_box(
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ die( 'You are not allowed to call this page directly.' );
4