PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.20
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.20
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/controllers/FrmHooksController.php +5 -50 6.356.20 View file →
@@ -12,16 +12,16 @@
12 12 *
13 13 * @return void
14 14 */
15 15 public static function trigger_load_hook( $hooks = 'load_hooks' ) {
16 - $controllers = apply_filters( 'frm_load_controllers', array( 'FrmHooksController' ) );
16 + $controllers = apply_filters( 'frm_load_controllers', array( 'FrmHooksController' ) );
17 +
17 18 $trigger_hooks = $hooks;
18 19 $hooks = (array) $hooks;
19 20
20 - if ( 'load_hooks' === $trigger_hooks ) {
21 + if ( 'load_hooks' == $trigger_hooks ) {
21 22 if ( is_admin() ) {
22 23 $hooks[] = 'load_admin_hooks';
23 -
24 24 if ( defined( 'DOING_AJAX' ) ) {
25 25 $hooks[] = 'load_ajax_hooks';
26 26 $hooks[] = 'load_form_hooks';
27 27 }
@@ -80,19 +80,11 @@
80 80 add_filter( 'frm_content', 'FrmFormsController::filter_content', 10, 3 );
81 81 add_filter( 'frm_replace_content_shortcodes', 'FrmFormsController::replace_content_shortcodes', 20, 3 );
82 82 add_action( 'admin_bar_init', 'FrmFormsController::admin_bar_css' );
83 83 add_action( 'wp_footer', 'FrmFormsController::footer_js', 1, 0 );
84 - add_action( 'wp_footer', 'FrmHoneypot::maybe_print_honeypot_js', 99 );
85 84
86 85 add_action( 'wp_scheduled_delete', 'FrmForm::scheduled_delete' );
87 86
88 - // Clear embed posts transient when posts are updated.
89 - add_action( 'wp_insert_post', 'FrmFormsListHelper::maybe_clear_embed_posts_transient', 10, 3 );
90 - add_action( 'post_updated', 'FrmFormsListHelper::maybe_clear_embed_posts_transient_on_update', 10, 3 );
91 - add_action( 'trashed_post', 'FrmFormsListHelper::clear_embed_posts_transient_for_post' );
92 - add_action( 'untrashed_post', 'FrmFormsListHelper::clear_embed_posts_transient_for_post' );
93 - add_action( 'deleted_post', 'FrmFormsListHelper::clear_embed_posts_transient_for_post', 10, 2 );
94 -
95 87 // Form Shortcodes.
96 88 add_shortcode( 'formidable', 'FrmFormsController::get_form_shortcode' );
97 89
98 90 // Styles Controller.
@@ -103,8 +95,9 @@
103 95
104 96 // Simple Blocks Controller.
105 97 add_action( 'init', 'FrmSimpleBlocksController::register_simple_form_block' );
106 98
99 + add_filter( 'cron_schedules', 'FrmUsageController::add_schedules' );
107 100 add_action( 'formidable_send_usage', 'FrmUsageController::send_snapshot' );
108 101
109 102 /**
110 103 * Make name field work with View.
@@ -117,26 +110,10 @@
117 110
118 111 // Summary emails.
119 112 add_action( 'frm_daily_event', 'FrmEmailSummaryController::maybe_send_emails' );
120 113
121 - // Gated Content — daily cleanup of expired tokens.
122 - add_action( 'frm_daily_event', 'FrmGatedTokenHelper::cleanup_expired' );
123 -
124 - // Gated Content Controller.
125 - add_action( 'frm_trigger_gated_content_action', 'FrmGatedContentController::trigger', 10, 4 );
126 - // pre_get_posts: allows private posts into the query when a valid token is present.
127 - add_action( 'pre_get_posts', 'FrmGatedContentController::maybe_include_private_posts' );
128 - // 'wp' fires after WP::query_posts() so get_queried_object_id() is available.
129 - add_action( 'wp', 'FrmGatedContentController::maybe_unlock_post' );
130 - add_action( 'save_post_frm_form_actions', 'FrmGatedContentController::on_action_updated', 10, 3 );
131 - add_action( 'before_delete_post', 'FrmGatedContentController::on_action_deleted', 10, 2 );
132 - add_shortcode( 'frm_gated_content', 'FrmGatedContentShortcodeController::shortcode' );
133 - add_filter( 'frm_helper_shortcodes', 'FrmGatedContentController::add_shortcode_helper', 10, 3 );
134 -
135 114 FrmTransLiteHooksController::load_hooks();
136 115 FrmStrpLiteHooksController::load_hooks();
137 - FrmSquareLiteHooksController::load_hooks();
138 - FrmPayPalLiteHooksController::load_hooks();
139 116
140 117 // GDPR
141 118 add_filter( 'frm_is_field_required', 'FrmFieldGdpr::force_required_field', 10, 2 );
142 119 }
@@ -167,21 +144,16 @@
167 144 }
168 145
169 146 add_action( 'frm_after_duplicate_form', 'FrmFormActionsController::duplicate_form_actions', 20, 3 );
170 147
171 - // Fields Model.
172 - add_filter( 'frm_pro_available_fields', 'FrmField::show_update_for_pro_fields' );
173 -
174 148 // Forms Controller.
175 149 add_action( 'admin_menu', 'FrmFormsController::menu', 10 );
176 150 add_action( 'admin_head-toplevel_page_formidable', 'FrmFormsController::head' );
177 151 add_action( 'frm_after_field_options', 'FrmFormsController::logic_tip' );
178 - add_action( 'frm_field_code_tab', 'FrmFormsController::field_part_shortcodes' );
179 - add_filter( 'frm_fields_in_form_builder', 'FrmFormsController::update_form_builder_fields' );
152 + add_filter( 'frm_fields_in_form_builder', 'FrmFormsController::update_form_builder_fields', 10, 2 );
180 153
181 154 add_filter( 'set-screen-option', 'FrmFormsController::save_per_page', 10, 3 );
182 155 add_action( 'admin_footer', 'FrmFormsController::insert_form_popup' );
183 - add_action( 'admin_footer', 'FrmFormsController::print_forms_list_templates' );
184 156
185 157 // Elementor.
186 158 add_action( 'elementor/editor/footer', 'FrmElementorController::admin_init' );
187 159
@@ -207,9 +179,8 @@
207 179 add_action( 'admin_menu', 'FrmXMLController::menu', 41 );
208 180
209 181 // Simple Blocks Controller.
210 182 add_action( 'enqueue_block_editor_assets', 'FrmSimpleBlocksController::block_editor_assets' );
211 - add_action( 'enqueue_block_assets', 'FrmSimpleBlocksController::block_assets' );
212 183
213 184 add_action( 'admin_init', 'FrmUsageController::schedule_send' );
214 185
215 186 // Applications Controller.
@@ -230,17 +201,11 @@
230 201 add_action( 'admin_enqueue_scripts', 'FrmDeactivationFeedbackController::enqueue_assets' );
231 202 add_action( 'admin_footer', 'FrmDeactivationFeedbackController::footer_html' );
232 203 add_action( 'deactivated_plugin', 'FrmDeactivationFeedbackController::set_feedback_expired_date' );
233 204
234 - add_action( 'frm_email_styles_extra_settings', 'FrmEmailStylesController::show_upsell_settings' );
235 -
236 - add_action( 'admin_init', 'FrmWelcomeTourController::admin_init' );
237 -
238 205 FrmDashboardController::load_admin_hooks();
239 206 FrmTransLiteHooksController::load_admin_hooks();
240 207 FrmStrpLiteHooksController::load_admin_hooks();
241 - FrmSquareLiteHooksController::load_admin_hooks();
242 - FrmPayPalLiteHooksController::load_admin_hooks();
243 208 FrmSMTPController::load_hooks();
244 209 FrmOnboardingWizardController::load_admin_hooks();
245 210 FrmAddonsController::load_admin_hooks();
246 211 new FrmPluginSearch();
@@ -296,9 +261,8 @@
296 261
297 262 // Form Templates Controller.
298 263 add_action( 'wp_ajax_frm_add_or_remove_favorite_template', 'FrmFormTemplatesController::ajax_add_or_remove_favorite' );
299 264 add_action( 'wp_ajax_frm_create_template', 'FrmFormTemplatesController::ajax_create_template' );
300 - add_action( 'wp_ajax_frm_get_free_templates', 'FrmFormTemplatesController::ajax_get_free_templates' );
301 265
302 266 // Inbox.
303 267 add_action( 'wp_ajax_frm_inbox_dismiss', 'FrmInboxController::dismiss_message' );
304 268
@@ -336,17 +300,8 @@
336 300 add_action( 'wp_ajax_frm_get_applications_data', 'FrmApplicationsController::get_applications_data' );
337 301
338 302 // Reviews.
339 303 add_action( 'wp_ajax_frm_dismiss_review', 'FrmAppController::dismiss_review' );
340 - add_action( 'wp_ajax_frm_small_screen_proceed', 'FrmAppController::small_screen_proceed' );
341 - add_action( 'wp_ajax_frm_sale_banner_dismiss', 'FrmSalesApi::dismiss_banner' );
342 -
343 - add_action( 'wp_ajax_frm_email_style_preview', 'FrmEmailStylesController::ajax_preview' );
344 - add_action( 'wp_ajax_frm_send_test_email', 'FrmEmailStylesController::ajax_send_test_email' );
345 -
346 - // Welcome Tour.
347 - add_action( 'wp_ajax_frm_mark_checklist_step_as_completed', 'FrmWelcomeTourController::ajax_mark_checklist_step_as_completed' );
348 - add_action( 'wp_ajax_frm_dismiss_welcome_tour', 'FrmWelcomeTourController::ajax_dismiss_welcome_tour' );
349 304 }
350 305
351 306 /**
352 307 * @return void