Contact Form 7 Multi-Step Forms - Version 2.0.3

Version Description

fixed issue where server variables may not be defined. added some support for strings to be translatable.

Download this release

Release Info

Developer webheadllc
Plugin Icon 128x128 Contact Form 7 Multi-Step Forms
Version 2.0.3
Comparing to
See all releases

Code changes from version 2.0.2 to 2.0.3

contact-form-7-multi-step-module.php CHANGED
@@ -5,7 +5,7 @@ Plugin URI: http://www.mymonkeydo.com/contact-form-7-multi-step-module/
5
  Description: Enables the Contact Form 7 plugin to create multi-page, multi-step forms.
6
  Author: Webhead LLC.
7
  Author URI: http://webheadcoder.com
8
- Version: 2.0.2
9
  */
10
  /* Copyright 2012 Webhead LLC (email: info at webheadcoder.com)
11
 
@@ -24,7 +24,7 @@ Version: 2.0.2
24
  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
25
  */
26
 
27
- define( 'CF7MSM_VERSION', '2.0.2' );
28
  define( 'CF7MSM_PLUGIN', __FILE__ );
29
  define( 'CF7MSM_FREE_TEXT_PREFIX_RADIO', '_wpcf7_radio_free_text_' );
30
  define( 'CF7MSM_FREE_TEXT_PREFIX_CHECKBOX', '_wpcf7_checkbox_free_text_' );
@@ -215,11 +215,11 @@ function cf7msm_step_2($cf7) {
215
  || ($matches[1] != 1 && ((int) $step) + 1 < $matches[1]) ) {
216
  if ( $has_wpcf7_class ) {
217
  $cf7->set_properties( array(
218
- 'form' => apply_filters('wh_hide_cf7_step_message', "Please fill out the form on the previous page")
219
  ) );
220
  }
221
  else {
222
- $cf7->form = apply_filters('wh_hide_cf7_step_message', "Please fill out the form on the previous page");
223
  }
224
  }
225
  if (count($matches) >= 3 && $matches[1] != $matches[2]) {
@@ -403,11 +403,11 @@ function parse_form_for_multistep_url( $wpcf7 ) {
403
  */
404
  function cf7msm_current_url() {
405
  $page_url = 'http';
406
- if ($_SERVER["HTTPS"] == "on") {
407
  $page_url .= "s";
408
  }
409
  $page_url .= "://";
410
- if ($_SERVER["SERVER_PORT"] != "80") {
411
  $page_url .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
412
  } else {
413
  $page_url .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
5
  Description: Enables the Contact Form 7 plugin to create multi-page, multi-step forms.
6
  Author: Webhead LLC.
7
  Author URI: http://webheadcoder.com
8
+ Version: 2.0.3
9
  */
10
  /* Copyright 2012 Webhead LLC (email: info at webheadcoder.com)
11
 
24
  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
25
  */
26
 
27
+ define( 'CF7MSM_VERSION', '2.0.3' );
28
  define( 'CF7MSM_PLUGIN', __FILE__ );
29
  define( 'CF7MSM_FREE_TEXT_PREFIX_RADIO', '_wpcf7_radio_free_text_' );
30
  define( 'CF7MSM_FREE_TEXT_PREFIX_CHECKBOX', '_wpcf7_checkbox_free_text_' );
215
  || ($matches[1] != 1 && ((int) $step) + 1 < $matches[1]) ) {
216
  if ( $has_wpcf7_class ) {
217
  $cf7->set_properties( array(
218
+ 'form' => apply_filters('wh_hide_cf7_step_message', __( 'Please fill out the form on the previous page', 'cf7msm' ) )
219
  ) );
220
  }
221
  else {
222
+ $cf7->form = apply_filters('wh_hide_cf7_step_message', __( 'Please fill out the form on the previous page', 'cf7msm' ) );
223
  }
224
  }
225
  if (count($matches) >= 3 && $matches[1] != $matches[2]) {
403
  */
404
  function cf7msm_current_url() {
405
  $page_url = 'http';
406
+ if ( isset( $_SERVER["HTTPS"] ) && $_SERVER["HTTPS"] == "on") {
407
  $page_url .= "s";
408
  }
409
  $page_url .= "://";
410
+ if ( isset( $_SERVER["SERVER_PORT"] ) && $_SERVER["SERVER_PORT"] != "80") {
411
  $page_url .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
412
  } else {
413
  $page_url .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
form-tags/module-back.php CHANGED
@@ -49,11 +49,11 @@ function cf7msm_back_shortcode_handler( $tag ) {
49
  $value = isset( $tag->values[0] ) ? $tag->values[0] : '';
50
  if ( empty( $value ) ) {
51
  if ( $tag->type == 'previous') {
52
- $value = __( 'Previous', 'cpf7msm' );
53
  }
54
  else {
55
  //using old version
56
- $value = __( 'Back', 'cpf7msm' );
57
  }
58
  }
59
 
49
  $value = isset( $tag->values[0] ) ? $tag->values[0] : '';
50
  if ( empty( $value ) ) {
51
  if ( $tag->type == 'previous') {
52
+ $value = __( 'Previous', 'cf7msm' );
53
  }
54
  else {
55
  //using old version
56
+ $value = __( 'Back', 'cf7msm' );
57
  }
58
  }
59
 
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: webheadllc
3
  Donate Link: http://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: 3.4.1
6
- Tested up to: 4.5
7
- Stable tag: 2.0.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -56,12 +56,11 @@ Sample of this working is at [http://webheadcoder.com/contact-form-7-multi-step-
56
 
57
  == Frequently Asked Questions ==
58
 
59
-
60
- = Why "place your cursor at the end of the form" before inserting the multistep tag? =
61
 
62
  The `multistep` form tag is a hidden field and tries not to add any spacing to your form. In this effort, anything directly after this tag may be hidden. To prevent this, add a carriage return after the `multistep` form tag, or just follow the directions and place the form tag at the end of the form.
63
 
64
-
65
  = I keep getting the "Please fill out the form on the previous page" message. What's wrong? =
66
 
67
  If you have everything set up correctly and you get a message saying, "Please fill out the form on the previous page" after submitting the first form, then it's probably your caching system not allowing cookies to be set in the normal way. No workarounds or fixes are planned at this time. You will need to turn off caching for the affected pages.
@@ -92,9 +91,17 @@ Yes, you can, but it requires you to add code to your theme's functions.php file
92
 
93
  This is caused by a multistep form tag not having the correct step. For example your form for step 2 of 3 may have `[multistep "1-3-http://a.com/step-3"]`, but instead it should be `[multistep "2-3-http://a.com/step-3"]`.
94
 
 
 
 
 
95
 
96
  == Changelog ==
97
 
 
 
 
 
98
  = 2.0.2 =
99
  Fix previous button not showing class attribute.
100
 
3
  Donate Link: http://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: 3.4.1
6
+ Tested up to: 4.5.2
7
+ Stable tag: 2.0.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
56
 
57
  == Frequently Asked Questions ==
58
 
59
+ = The Next button doesn't show up =
60
+ Like all Contact Form 7 forms, you still need to add a button to submit the form. Use the normal submit button with any label you want like so `[submit "Next"]`.
61
 
62
  The `multistep` form tag is a hidden field and tries not to add any spacing to your form. In this effort, anything directly after this tag may be hidden. To prevent this, add a carriage return after the `multistep` form tag, or just follow the directions and place the form tag at the end of the form.
63
 
 
64
  = I keep getting the "Please fill out the form on the previous page" message. What's wrong? =
65
 
66
  If you have everything set up correctly and you get a message saying, "Please fill out the form on the previous page" after submitting the first form, then it's probably your caching system not allowing cookies to be set in the normal way. No workarounds or fixes are planned at this time. You will need to turn off caching for the affected pages.
91
 
92
  This is caused by a multistep form tag not having the correct step. For example your form for step 2 of 3 may have `[multistep "1-3-http://a.com/step-3"]`, but instead it should be `[multistep "2-3-http://a.com/step-3"]`.
93
 
94
+ = Why "place your cursor at the end of the form" before inserting the multistep tag? =
95
+
96
+ The `multistep` form tag is a hidden field and tries not to add any spacing to your form. In this effort, anything directly after this tag may be hidden. To prevent this, add a carriage return after the `multistep` form tag, or just follow the directions and place the form tag at the end of the form.
97
+
98
 
99
  == Changelog ==
100
 
101
+ = 2.0.3 =
102
+ fixed issue where server variables may not be defined. added some support for strings to be translatable.
103
+
104
+
105
  = 2.0.2 =
106
  Fix previous button not showing class attribute.
107