Plugin Directory

Changeset 3353641


Ignore:
Timestamp:
09/01/2025 06:03:57 AM (3 months ago)
Author:
themefic
Message:

update 3.5.27

Location:
ultimate-addons-for-contact-form-7
Files:
1174 added
7 edited

Legend:

Unmodified
Added
Removed
  • ultimate-addons-for-contact-form-7/trunk/addons/conditional-field/conditional-fields.php

    r3333753 r3353641  
    705705        $uacf7_conditions = uacf7_get_form_option( $id, 'conditional' );
    706706        $conditional_repeater = isset( $uacf7_conditions['conditional_repeater'] ) ? $uacf7_conditions['conditional_repeater'] : array();
    707         $posted_data = (array) $contact_form_data;
     707
     708        // ✅ Use raw posted data from submission, not the normalized $contact_form_data
     709        $submission = WPCF7_Submission::get_instance();
     710        $posted_data = $submission ? $submission->get_posted_data() : (array) $contact_form_data;
    708711
    709712        if ( is_array( $conditional_repeater ) && ! empty( $conditional_repeater ) ) {
     
    716719                $condition_status = [];
    717720
    718                 // Check if the conditional field is hidden or shown
    719                 foreach ( $uacf7_cf_conditions as $key => $value ) {
    720                     $uacf7_cf_val = $value['uacf7_cf_val'];
    721                     $uacf7_cf_operator = $value['uacf7_cf_operator'];
    722                     $uacf7_cf_tn = $value['uacf7_cf_tn'];
    723 
    724 
    725                     $posted_value = is_array( $posted_data[ $uacf7_cf_tn ] ) && in_array( $uacf7_cf_val, $posted_data[ $uacf7_cf_tn ] ) ? $uacf7_cf_val : $posted_data[ $uacf7_cf_tn ];
    726 
    727                     // Condition for Equal 
     721                foreach ( $uacf7_cf_conditions as $c ) {
     722                    $uacf7_cf_val = $c['uacf7_cf_val'];
     723                    $uacf7_cf_operator = $c['uacf7_cf_operator'];
     724                    $uacf7_cf_tn = rtrim( $c['uacf7_cf_tn'], '[]' );
     725
     726                    // ✅ Normalize posted value
     727                    $posted_value = isset($posted_data[$uacf7_cf_tn])
     728                        ? ( is_array($posted_data[$uacf7_cf_tn]) ? implode(',', $posted_data[$uacf7_cf_tn]) : $posted_data[$uacf7_cf_tn] )
     729                        : '';
     730
     731                    // ✅ Same condition checks as your mail function
    728732                    if ( $uacf7_cf_operator == 'equal' && $posted_value == $uacf7_cf_val ) {
    729733                        $condition_status[] = 'true';
    730734                    }
    731                     // Condition for Not Equal
    732                     else if ( $uacf7_cf_operator == 'not_equal' && $posted_value != $uacf7_cf_val ) {
    733 
    734                         $condition_status[] = 'true';
    735                     }
    736                     // Condition for Greater than
    737                     else if ( $uacf7_cf_operator == 'greater_than' && $posted_value > $uacf7_cf_val ) {
    738                         $condition_status[] = 'true';
    739                     }
    740                     // Condition for Less than
    741                     else if ( $uacf7_cf_operator == 'less_than' && $posted_value < $uacf7_cf_val ) {
    742                         $condition_status[] = 'true';
    743                     }
    744                     // Condition for Greater than or equal to
    745                     else if ( $uacf7_cf_operator == 'greater_than_or_equal_to' && $posted_value >= $uacf7_cf_val ) {
    746                         $condition_status[] = 'true';
    747                     }
    748                     // Condition for Less than or equal to
    749                     else if ( $uacf7_cf_operator == 'less_than_or_equal_to' && $posted_value <= $uacf7_cf_val ) {
    750                         $condition_status[] = 'true';
    751                     }
    752                     // Condition for Starts With
    753                     else if ( $uacf7_cf_operator == 'starts_with' && substr( $posted_value, 0, strlen( $uacf7_cf_val ) ) === $uacf7_cf_val ) {
    754                         $condition_status[] = 'true';
    755                     }
    756                     // Condition for Ends With
    757                     else if ( $uacf7_cf_operator == 'ends_with' && substr( $posted_value, -strlen( $uacf7_cf_val ) ) === $uacf7_cf_val ) {
    758                         $condition_status[] = 'true';
    759                     }     
    760                     // Condition for Contains
    761                     else if ( $uacf7_cf_operator == 'contains' && strpos( $posted_value, $uacf7_cf_val ) !== false ) {
    762                         $condition_status[] = 'true';
    763                     }     
    764                     // Condition for Excludes (does not contain)
    765                     else if ( $uacf7_cf_operator == 'does_not_contain' && strpos( $posted_value, $uacf7_cf_val ) === false ) {
    766                         $condition_status[] = 'true';
    767                     }else {
     735                    elseif ( $uacf7_cf_operator == 'not_equal' && $posted_value != $uacf7_cf_val ) {
     736                        $condition_status[] = 'true';
     737                    }
     738                    elseif ( $uacf7_cf_operator == 'contains' && strpos($posted_value, $uacf7_cf_val) !== false ) {
     739                        $condition_status[] = 'true';
     740                    }
     741                    elseif ( $uacf7_cf_operator == 'does_not_contain' && strpos($posted_value, $uacf7_cf_val) === false ) {
     742                        $condition_status[] = 'true';
     743                    }
     744                    else {
    768745                        $condition_status[] = 'false';
    769746                    }
    770747                }
    771748
    772 
    773                 // Check if the conditions for all 
    774                 if ( $uacf7_cf_conditions_for == 'all' ) {
    775                     if ( ! in_array( 'false', $condition_status ) ) {
    776                         if ( $uacf7_cf_hs == 'show' ) {
    777 
    778                             $pdf_content = preg_replace( '/\[' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    779                             $pdf_content = preg_replace( '/\[\/' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    780 
    781                         }
    782                     } else {
    783                         $pdf_content = preg_replace( '/\[' . $uacf7_cf_group . '\].*?\[\/' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    784 
    785                     }
    786                 }
    787                 // Check if the conditions for all
    788                 if ( $uacf7_cf_conditions_for == 'any' ) {
    789                     if ( ! in_array( 'false', $condition_status ) ) {
    790 
    791                         if ( $uacf7_cf_hs == 'show' ) {
    792                             $pdf_content = preg_replace( '/\[' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    793                             $pdf_content = preg_replace( '/\[\/' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    794 
    795                         }
    796                     } else {
    797                         $pdf_content = preg_replace( '/\[' . $uacf7_cf_group . '\].*?\[\/' . $uacf7_cf_group . '\]/s', '', $pdf_content );
    798 
    799                     }
     749                // Replace content (same as your mail logic)
     750                if ( $uacf7_cf_conditions_for == 'all' && ! in_array('false', $condition_status) ) {
     751                    if ( $uacf7_cf_hs == 'show' ) {
     752                        $pdf_content = preg_replace( '/\['.$uacf7_cf_group.'\]/s', '', $pdf_content );
     753                        $pdf_content = preg_replace( '/\[\/'.$uacf7_cf_group.'\]/s', '', $pdf_content );
     754                    }
     755                } elseif ( $uacf7_cf_conditions_for == 'any' && in_array('true', $condition_status) ) {
     756                    if ( $uacf7_cf_hs == 'show' ) {
     757                        $pdf_content = preg_replace( '/\['.$uacf7_cf_group.'\]/s', '', $pdf_content );
     758                        $pdf_content = preg_replace( '/\[\/'.$uacf7_cf_group.'\]/s', '', $pdf_content );
     759                    }
     760                } else {
     761                    $pdf_content = preg_replace( '/\['.$uacf7_cf_group.'\].*?\[\/'.$uacf7_cf_group.'\]/s', '', $pdf_content );
    800762                }
    801763            }
    802764        }
    803765
    804 
    805766        return $pdf_content;
    806767    }
     768
    807769
    808770
  • ultimate-addons-for-contact-form-7/trunk/addons/multistep/assets/js/multistep.js

    r3316177 r3353641  
    1 jQuery(document).ready(function () {
    2 
    3     jQuery('.wpcf7-form').each(function () {
    4         // Is Repeater Use in form
    5         var repeater_count = jQuery(this).find('.uacf7-repeater-count').val();
    6 
    7         var uacf7_sid = 1;
    8         var form_id = jQuery(this).find("input[name=_wpcf7]").val();
    9         var uacf7_next = jQuery(this).find('.uacf7-next[data-form-id="' + form_id + '"]');
    10         var uacf7_prev = jQuery(this).find('.uacf7-prev[data-form-id="' + form_id + '"]');
    11         var uacf7_step = '.uacf7-step-' + form_id;
    12         var total_steps = jQuery(uacf7_step, this).length;
    13 
    14         jQuery(uacf7_step, this).each(function () {
    15             var $this = jQuery(this);
    16             $this.attr('id', form_id + 'step-' + uacf7_sid);
    17             $this.attr('step-id', uacf7_sid);
    18 
    19             if (uacf7_sid == 1) {
    20                 $this.addClass('step-start');
    21             }
    22 
    23             if (total_steps == uacf7_sid) {
    24                 $this.addClass('step-end');
    25             }
    26 
    27             uacf7_sid++;
    28 
    29         });
    30         uacf7_prev.on('click', function (e) {
    31             e.preventDefault();
    32         });
    33 
    34         uacf7_next.on('click', function (e) {
    35             e.preventDefault();
    36 
    37             var $this = jQuery(this);
    38             uacf7_step_validation($this, uacf7_step, form_id, repeater_count);
    39         });
    40     });
     1(function($){
     2
     3    function initUACF7MultiStep($context) {
     4        $context.find('.wpcf7').each(function(){
     5            // Is Repeater Use in form
     6            var repeater_count = jQuery(this).find('.uacf7-repeater-count').val();
     7
     8            var uacf7_sid = 1;
     9            var form_id = jQuery(this).find("input[name=_wpcf7]").val();
     10            var uacf7_next = jQuery(this).find('.uacf7-next[data-form-id="' + form_id + '"]');
     11            var uacf7_prev = jQuery(this).find('.uacf7-prev[data-form-id="' + form_id + '"]');
     12            var uacf7_step = '.uacf7-step-' + form_id;
     13            var total_steps = jQuery(uacf7_step, this).length;
     14
     15            jQuery(uacf7_step, this).each(function () {
     16                var $this = jQuery(this);
     17                $this.attr('id', form_id + 'step-' + uacf7_sid);
     18                $this.attr('step-id', uacf7_sid);
     19
     20                if (uacf7_sid == 1) {
     21                    $this.addClass('step-start');
     22                }
     23
     24                if (total_steps == uacf7_sid) {
     25                    $this.addClass('step-end');
     26                }
     27
     28                uacf7_sid++;
     29
     30            });
     31            uacf7_prev.on('click', function (e) {
     32                e.preventDefault();
     33            });
     34
     35            uacf7_next.on('click', function (e) {
     36                e.preventDefault();
     37
     38                var $this = jQuery(this);
     39                uacf7_step_validation($this, uacf7_step, form_id, repeater_count);
     40            });
     41        });
     42    }
    4143
    4244
     
    264266        });
    265267    }
     268
    266269    function acceptance_validation_disabled_button($this, invert, optional, uacf7_next, checked) {
    267270        if (invert == true && checked == false) {
     
    282285    }
    283286
    284 });
     287
     288    // On document ready (first load)
     289    $(document).ready(function(){
     290        initUACF7MultiStep($(document));
     291    });
     292
     293    // When Elementor popup opens
     294    $(document).on('elementor/popup/show', function(event, id, instance){
     295        var $popup = $(instance.$element);
     296        initUACF7MultiStep($popup);
     297    });
     298
     299})(jQuery);
  • ultimate-addons-for-contact-form-7/trunk/addons/multistep/assets/js/progressbar.js

    r3007616 r3353641  
    11(function ($) {
    22
    3     $(document).ready(function () {
    4         jQuery('.wpcf7-form').each(function(){
     3    function initUacf7Progressbar($scope) {
     4        $scope.find('.wpcf7-form').each(function () {
    55                var form_id = $(this).find("input[name=_wpcf7]").val(),
    66                navListItems  = $(this).find('.uacf7-steps div.setup-panel div a[data-form-id="' + form_id + '"]'),
     
    4141                            $target.find('input:eq(0)').focus();
    4242                        }
    43                      }
    44                    
     43                    }
     44               
    4545                });
    4646
     
    7676        });
    7777       
     78    }
     79
     80    // Run on normal page load
     81    $(document).ready(function () {
     82        initUacf7Progressbar($(document));
    7883    });
     84
     85    // Run again when Elementor popup opens
     86    $(document).on('elementor/popup/show', function (event, id, instance) {
     87        var $popup = $(instance.$element);
     88        initUacf7Progressbar($popup);
     89    });
     90
    7991})(jQuery);
  • ultimate-addons-for-contact-form-7/trunk/admin/tf-options/classes/UACF7_Settings.php

    r3333753 r3353641  
    1111        public $option_position = null;
    1212        public $option_sections = array();
    13         public $pre_tabs = '';
     13        public $pre_tabs = array();
    1414        public $pre_fields = '';
    1515        public $pre_sections = '';
     
    193193                <div class="other-document">
    194194                    <svg width="26" height="25" viewBox="0 0 26 25" fill="none" xmlns="http://www.w3.org/2000/svg"
    195                         style="color: #003c79;background: ;">
     195                        style="color: #003c79;">
    196196                        <path
    197197                            d="M19.2106 0H6.57897C2.7895 0 0.263184 2.52632 0.263184 6.31579V13.8947C0.263184 17.6842 2.7895 20.2105 6.57897 20.2105V22.9011C6.57897 23.9116 7.70318 24.5179 8.53687 23.9495L14.1579 20.2105H19.2106C23 20.2105 25.5263 17.6842 25.5263 13.8947V6.31579C25.5263 2.52632 23 0 19.2106 0ZM12.8948 15.3726C12.3642 15.3726 11.9474 14.9432 11.9474 14.4253C11.9474 13.9074 12.3642 13.4779 12.8948 13.4779C13.4253 13.4779 13.8421 13.9074 13.8421 14.4253C13.8421 14.9432 13.4253 15.3726 12.8948 15.3726ZM14.4863 10.1305C13.9937 10.4589 13.8421 10.6737 13.8421 11.0274V11.2926C13.8421 11.8105 13.4127 12.24 12.8948 12.24C12.3769 12.24 11.9474 11.8105 11.9474 11.2926V11.0274C11.9474 9.56211 13.0211 8.84211 13.4253 8.56421C13.8927 8.24842 14.0442 8.03368 14.0442 7.70526C14.0442 7.07368 13.5263 6.55579 12.8948 6.55579C12.2632 6.55579 11.7453 7.07368 11.7453 7.70526C11.7453 8.22316 11.3158 8.65263 10.7979 8.65263C10.28 8.65263 9.85055 8.22316 9.85055 7.70526C9.85055 6.02526 11.2148 4.66105 12.8948 4.66105C14.5748 4.66105 15.939 6.02526 15.939 7.70526C15.939 9.14526 14.8779 9.86526 14.4863 10.1305Z"
  • ultimate-addons-for-contact-form-7/trunk/admin/tf-options/options/uacf7-settings.php

    r3333753 r3353641  
    588588                                'is_pro'             => true,
    589589                                'subtitle'           => __( 'Add specific WooCommerce products as dropdowns based on Product ID, with options to connect to Cart/Checkout and show products based on categories or IDs. ', 'ultimate-addons-cf7' ),
    590                                 'demo_link'          => 'https://cf7addons.com/pricing/duct-grid-view-with-thumbnails/',
     590                                'demo_link'          => 'https://cf7addons.com/preview/woocommerce-product-dropdown/',
    591591                                'documentation_link' => 'https://themefic.com/docs/uacf7/pro-addons/contact-form-7-woocommerce-pro/',
    592592                            ),
  • ultimate-addons-for-contact-form-7/trunk/readme.txt

    r3342208 r3353641  
    55Tested up to: 6.8
    66Requires PHP: 7.4
    7 Stable tag: 3.5.26
     7Stable tag: 3.5.27
    88License: GPL-2.0+
    99License URI: http://www.gnu.org/licenses/gpl-2.0.txt
     
    228228= Contact Form 7 to Blog Submission =
    229229
    230 Create a [Frontend post submission form](https://cf7addons.com/preview/contact-form-7-to-post-type/) with Contact Form 7. Each submission publishes a new post you can manage from your dashboard and display on your site. Add title, description, category, and featured image by default. Connect any custom field using the Custom Field feature for added flexibility.
     230Create a [Frontend post submission form](https://cf7addons.com/preview/contact-form-7-to-post-type/) with Contact Form 7. Each submission publishes a new post you can manage from your dashboard and display on your site. Add title, description, category, and featured image by default. Easily connect any custom fields for added flexibility.
    231231
    232232= Contact Form 7 to Custom Post Type =
     
    252252= Contact Form 7 Star Rating Field Pro =
    253253
    254 While the free version offers one Star Field icon, the Pro version enhances your options with [5 Built-In Rating Styles](https://cf7addons.com/preview/star-rating-pro/). If these styles don't meet your needs, the Pro version further allows the addition of any icon from Font Awesome.
     254While the free version offers one Star Field icon, the Pro version enhances your options with [5 Built-In Rating Styles](https://cf7addons.com/preview/star-rating-pro/). If these styles don't meet your needs, the Pro version also allows adding any icon from Font Awesome.
    255255
    256256= Contact form 7 Whatsapp Integration + CF7 Tag Support  =
    257257
    258 Tag support for CF7 fields allows data to be passed through the redirect URL. Additionally, you can activate [WhatsApp Contact Form 7 integration](https://cf7addons.com/preview/contact-form-7-whatsapp-integration/). For instance, by using tag support in the format https://yourdomain.com/?name=[your-name], the name field can be forwarded to WhatsApp or any desired destination.
     258Tag support for CF7 fields allows data to pass through the redirect URL. Additionally, you can activate [WhatsApp Contact Form 7 integration](https://cf7addons.com/preview/contact-form-7-whatsapp-integration/). For instance, using tag support in the format https://yourdomain.com/?name=[your-name], the name field can be forwarded to WhatsApp or any desired destination.
    259259
    260260= Contact form 7 WooCommerce Checkout / Auto Add to Cart =
     
    264264= Choose Specific / Multiple / Categorize WooCommerce Product =
    265265
    266 The Pro version allows you to add [Specific WooCommerce Product](https://cf7addons.com/preview/woocommerce-product-dropdown/) to Contact Form 7 forms by Product ID. It also allows customers to select [Multiple WooCommerce Products](https://cf7addons.com/preview/multiple-product/) and displays products by [WooCommerce Category](https://cf7addons.com/preview/categorized-product/). A complete WooCommerce integration for Contact Form 7.
     266The Pro version allows you to add [Specific WooCommerce Product](https://cf7addons.com/preview/woocommerce-product-dropdown/) to Contact Form 7 forms by Product ID. It also lets customers select [Multiple WooCommerce Products](https://cf7addons.com/preview/multiple-product/) and displays products by [WooCommerce Category](https://cf7addons.com/preview/categorized-product/).
    267267
    268268= Contact Form 7 Product Grid View with Thumbnails =
    269269
    270 Display your products in an impressive [WooCommerce Grid View](https://cf7addons.com/preview/product-grid-view-with-thumbnails/), allowing for addition based on ID, Category, or Tags. This feature enhances the visual appeal and organization of your product listings.
     270Display products in [WooCommerce Grid View](https://cf7addons.com/preview/product-grid-view-with-thumbnails/), allowing addition based on ID, Category, or Tags. This feature enhances the visual appeal and organization of your product listings.
    271271
    272272= Spam protection Contact form 7 (Pro) =
     
    276276= Contact form 7 DB plugin (Pro) =
    277277
    278 [Contact form 7 Database plugin](https://cf7addons.com/preview/best-contact-form-7-database-addon/) Pro addon offers an advanced solution for managing and organizing form inquiries more efficiently.
     278[Contact Form 7 Database plugin](https://cf7addons.com/preview/best-contact-form-7-database-addon/) Pro addon offers an advanced solution for managing and organizing form inquiries more efficiently.
    279279
    280280= Mailchimp with Contact Form 7 (Pro) =
     
    284284= Contact form 7 Preview before submit =
    285285
    286 The [Contact form 7 preview](https://cf7addons.com/preview/form-preview-submission/) addon adds a submission preview feature to your forms, enabling users to review and confirm their information before submission. 
     286The [Contact Form 7 preview](https://cf7addons.com/preview/form-preview-submission/) addon adds a submission preview feature to your forms, enabling users to review and confirm their information before submission. 
    287287
    288288= Contact form 7 Save progress and Continue Later =
     
    482482== Changelog ==
    483483
    484 = 3.5.26 - 10/08/2025 =
    485 
    486 - Fixed: Styling issue with Form Styler radio and checkbox input fields.
    487 - Fixed: Prepopulate fields issue affecting select and checkbox inputs.
    488 - Fixed: Styling issue with Form Styler textarea issue has been resolved.
     484= 3.5.27 - 10/08/2025 =
     485
     486- Fixed: Multistep issue in Elementor Popup.
     487- Fixed: Conditional field issue in PDF generator.
    489488
    490489**Old Changelog can be found [here](https://cf7addons.com/changelog/)**.
  • ultimate-addons-for-contact-form-7/trunk/ultimate-addons-for-contact-form-7.php

    r3342208 r3353641  
    44 * Plugin URI: https://cf7addons.com/
    55 * Description: 50+ Essential Addons for Contact Form 7 - Conditional Fields, Multi Step Forms, Redirection, Form Templates, Columns, WooCommerce, Mailchimp and more, all in one.
    6  * Version: 3.5.26
     6 * Version: 3.5.27
    77 * Author: Themefic
    88 * Author URI: https://themefic.com/
     
    3131        define( 'UACF7_PATH', plugin_dir_path( __FILE__ ) );
    3232
    33         define( 'UACF7_VERSION', '3.5.26' );
     33        define( 'UACF7_VERSION', '3.5.27' );
    3434
    3535        if ( ! class_exists( 'Appsero\Client' ) ) {
Note: See TracChangeset for help on using the changeset viewer.