Changeset 3458095
- Timestamp:
- 02/10/2026 01:45:40 PM (7 weeks ago)
- Location:
- growify-ai/trunk
- Files:
-
- 3 edited
-
growify-ai.php (modified) (2 diffs)
-
includes/class-growify-ai-forms.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
growify-ai/trunk/growify-ai.php
r3454822 r3458095 3 3 * Plugin Name: Growify 4 4 * Description: The plugin lets you integrate Growify.ai analytics into your WordPress site effortlessly. Track visits, WooCommerce conversions and form submissions automatically. 5 * Version: 1. 15 * Version: 1.2 6 6 * Author: Growify 7 7 * Text Domain: growify-ai … … 15 15 } 16 16 17 define('GROWIFY_AI_VERSION', '1. 1');17 define('GROWIFY_AI_VERSION', '1.2'); 18 18 define('GROWIFY_AI_PLUGIN_DIR', plugin_dir_path(__FILE__)); 19 19 define('GROWIFY_AI_PLUGIN_URL', plugin_dir_url(__FILE__)); -
growify-ai/trunk/includes/class-growify-ai-forms.php
r3451999 r3458095 21 21 { 22 22 // Contact Form 7 23 if (defined('WPCF7_VERSION')) { 24 add_action('wpcf7_mail_sent', [$this, 'track_cf7']); 25 } 23 add_action('wpcf7_mail_sent', [$this, 'track_cf7']); 26 24 27 25 // WPForms 28 if (function_exists('wpforms')) { 29 add_action('wpforms_process_complete', [$this, 'track_wpforms'], 10, 4); 30 } 26 add_action('wpforms_process_complete', [$this, 'track_wpforms'], 10, 4); 31 27 32 28 // Gravity Forms 33 if (class_exists('GFCommon')) { 34 add_action('gform_after_submission', [$this, 'track_gravity'], 10, 2); 35 } 29 add_action('gform_after_submission', [$this, 'track_gravity'], 10, 2); 36 30 37 31 // Ninja Forms 38 if (class_exists('Ninja_Forms')) { 39 add_action('ninja_forms_after_submission', [$this, 'track_ninja_forms']); 40 } 32 add_action('ninja_forms_after_submission', [$this, 'track_ninja_forms']); 41 33 42 34 // Forminator 43 if (class_exists('Forminator')) { 44 add_action('forminator_custom_form_submit_before_set_fields', [$this, 'track_forminator'], 10, 3); 45 } 35 add_action('forminator_custom_form_submit_before_set_fields', [$this, 'track_forminator'], 10, 3); 46 36 47 37 // Fluent Forms 48 if (defined('FLUENTFORM_VERSION')) { 49 add_action('fluentform_before_insert_submission', [$this, 'track_fluent_forms'], 10, 1); 50 } 38 add_action('fluentform_before_insert_submission', [$this, 'track_fluent_forms'], 10, 1); 51 39 52 40 // Elementor Forms 53 if (class_exists('\ElementorPro\Plugin') || function_exists('pro_elements_plugin_load_plugin')) { 54 add_action('elementor_pro/forms/new_record', [$this, 'track_elementor_forms'], 10, 2); 55 } 41 add_action('elementor_pro/forms/new_record', [$this, 'track_elementor_forms'], 10, 2); 56 42 57 43 // Formidable Forms 58 if (class_exists('FrmAppHelper')) { 59 add_action('frm_after_create_entry', [$this, 'track_formidable'], 10, 2); 60 } 44 add_action('frm_after_create_entry', [$this, 'track_formidable'], 10, 2); 61 45 62 46 // Everest Forms 63 if (class_exists('EverestForms')) { 64 add_action('everest_forms_process_complete', [$this, 'track_everest_forms_complete'], 10, 4); 65 } 47 add_action('everest_forms_process_complete', [$this, 'track_everest_forms_complete'], 10, 4); 48 49 // Bricks Theme Forms 50 add_filter('bricks/form/response', [$this, 'track_bricks_form'], 10, 2); 66 51 } 67 52 … … 387 372 388 373 /** 374 * Track Bricks Builder Forms 375 * 376 * @param array $response Response data. 377 * @param object $form Bricks Form object. 378 * @return array 379 */ 380 public function track_bricks_form($response, $form) 381 { 382 $settings = $form->get_settings(); 383 $fields_data = []; 384 385 if (!empty($settings['fields'])) { 386 foreach ($settings['fields'] as $field) { 387 $field_id = isset($field['id']) ? $field['id'] : ''; 388 $field_label = isset($field['label']) ? $field['label'] : $field_id; 389 $value = $form->get_field_value($field_id); 390 if (is_array($value)) { 391 $value = implode(', ', $value); 392 } 393 $fields_data[] = [ 394 'key' => $field_id, 395 'label' => $field_label, 396 'value' => $value 397 ]; 398 } 399 } 400 401 $form_name = isset($settings['submissionFormName']) ? $settings['submissionFormName'] : 'Bricks Theme Form'; 402 403 $lead = $this->build_lead_payload($fields_data, 'Bricks Theme Forms', $form_name); 404 $this->set_lead_cookie($lead); 405 406 return $response; 407 } 408 409 /** 389 410 * Standardize field key or label for comparison 390 411 * -
growify-ai/trunk/readme.txt
r3454822 r3458095 4 4 Requires at least: 5.0 5 5 Tested up to: 6.9 6 Stable tag: 1. 16 Stable tag: 1.2 7 7 License: GPLv2 or later 8 8 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 61 61 = 1.1 = 62 62 * Minor update 63 64 = 1.2 = 65 * Added Bricks theme form support 66 * Simplified form hooks initiation
Note: See TracChangeset
for help on using the changeset viewer.