Version Description
added ability to skip over steps if it was previously submitted.
Download this release
Release Info
Developer | webheadllc |
Plugin | Contact Form 7 Multi-Step Forms |
Version | 3.1.2 |
Comparing to | |
See all releases |
Code changes from version 3.1.1 to 3.1.2
- cf7msm.php +20 -1
- contact-form-7-multi-step-module.php +2 -2
- readme.txt +5 -2
cf7msm.php
CHANGED
@@ -238,7 +238,26 @@ function cf7msm_step_2( $cf7 )
|
|
238 |
|
239 |
if ( !is_admin() && (preg_match( '/\\[multistep "(\\d+)-(\\d+)-?(.*)"\\]/', $formstring, $matches ) || preg_match( '/\\[hidden cf7msm-step "(\\d+)-(\\d+)"\\]/', $formstring, $matches )) ) {
|
240 |
$step = cf7msm_get( 'cf7msm-step' );
|
241 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
242 |
|
243 |
if ( $has_wpcf7_class ) {
|
244 |
$cf7->set_properties( array(
|
238 |
|
239 |
if ( !is_admin() && (preg_match( '/\\[multistep "(\\d+)-(\\d+)-?(.*)"\\]/', $formstring, $matches ) || preg_match( '/\\[hidden cf7msm-step "(\\d+)-(\\d+)"\\]/', $formstring, $matches )) ) {
|
240 |
$step = cf7msm_get( 'cf7msm-step' );
|
241 |
+
$missing_prev_step = (int) $step + 1 < $matches[1];
|
242 |
+
|
243 |
+
if ( $missing_prev_step ) {
|
244 |
+
$prev_urls = cf7msm_get( 'cf7msm_prev_urls' );
|
245 |
+
if ( !empty($prev_urls) ) {
|
246 |
+
foreach ( $prev_urls as $step_string => $url ) {
|
247 |
+
$step_parts = explode( '-', $step_string );
|
248 |
+
if ( !empty($step_parts) ) {
|
249 |
+
|
250 |
+
if ( (int) $step_parts[0] >= $matches[1] ) {
|
251 |
+
$missing_prev_step = false;
|
252 |
+
break;
|
253 |
+
}
|
254 |
+
|
255 |
+
}
|
256 |
+
}
|
257 |
+
}
|
258 |
+
}
|
259 |
+
|
260 |
+
if ( !isset( $matches[1] ) || $matches[1] != 1 && empty($step) || $matches[1] != 1 && $missing_prev_step ) {
|
261 |
|
262 |
if ( $has_wpcf7_class ) {
|
263 |
$cf7->set_properties( array(
|
contact-form-7-multi-step-module.php
CHANGED
@@ -6,7 +6,7 @@ Plugin URI: http://www.mymonkeydo.com/contact-form-7-multi-step-module/
|
|
6 |
Description: Enables the Contact Form 7 plugin to create multi-page, multi-step forms.
|
7 |
Author: Webhead LLC.
|
8 |
Author URI: http://webheadcoder.com
|
9 |
-
Version: 3.1.
|
10 |
Text Domain: contact-form-7-multi-step-module
|
11 |
*/
|
12 |
/* Copyright 2018 Webhead LLC (email: info at webheadcoder.com)
|
@@ -63,7 +63,7 @@ if ( !function_exists( 'cf7msm_fs' ) ) {
|
|
63 |
cf7msm_fs();
|
64 |
// Signal that SDK was initiated.
|
65 |
do_action( 'cf7msm_fs_loaded' );
|
66 |
-
define( 'CF7MSM_VERSION', '3.1.
|
67 |
define( 'CF7MSM_PLUGIN', __FILE__ );
|
68 |
define( 'CF7MSM_FREE_TEXT_PREFIX_RADIO', '_wpcf7_radio_free_text_' );
|
69 |
define( 'CF7MSM_FREE_TEXT_PREFIX_CHECKBOX', '_wpcf7_checkbox_free_text_' );
|
6 |
Description: Enables the Contact Form 7 plugin to create multi-page, multi-step forms.
|
7 |
Author: Webhead LLC.
|
8 |
Author URI: http://webheadcoder.com
|
9 |
+
Version: 3.1.2
|
10 |
Text Domain: contact-form-7-multi-step-module
|
11 |
*/
|
12 |
/* Copyright 2018 Webhead LLC (email: info at webheadcoder.com)
|
63 |
cf7msm_fs();
|
64 |
// Signal that SDK was initiated.
|
65 |
do_action( 'cf7msm_fs_loaded' );
|
66 |
+
define( 'CF7MSM_VERSION', '3.1.2' );
|
67 |
define( 'CF7MSM_PLUGIN', __FILE__ );
|
68 |
define( 'CF7MSM_FREE_TEXT_PREFIX_RADIO', '_wpcf7_radio_free_text_' );
|
69 |
define( 'CF7MSM_FREE_TEXT_PREFIX_CHECKBOX', '_wpcf7_checkbox_free_text_' );
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: webheadllc
|
|
3 |
Donate Link: https://webheadcoder.com/donate-cf7-multi-step-forms
|
4 |
Tags: contact form 7, multistep form, form, multiple pages, store form, contact, multi, step
|
5 |
Requires at least: 4.7
|
6 |
-
Tested up to: 5.2.
|
7 |
-
Stable tag: 3.1.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -122,6 +122,9 @@ add_action( 'wpcf7_submit', 'my_prevent_saving', 9, 2 );
|
|
122 |
|
123 |
== Changelog ==
|
124 |
|
|
|
|
|
|
|
125 |
= 3.1.1 =
|
126 |
updated freemius.
|
127 |
|
3 |
Donate Link: https://webheadcoder.com/donate-cf7-multi-step-forms
|
4 |
Tags: contact form 7, multistep form, form, multiple pages, store form, contact, multi, step
|
5 |
Requires at least: 4.7
|
6 |
+
Tested up to: 5.2.3
|
7 |
+
Stable tag: 3.1.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
122 |
|
123 |
== Changelog ==
|
124 |
|
125 |
+
= 3.1.2 =
|
126 |
+
added ability to skip over steps if it was previously submitted.
|
127 |
+
|
128 |
= 3.1.1 =
|
129 |
updated freemius.
|
130 |
|