Version Description
- Tweak: Remove recaptcha and website fields from sample Contact us form template since most people don't need them
- Fix: Updates for WP 4.9 compatibility. This includes preventing double filtering on contact form widgets and using the WordPress Codemirror scripts for the form CSS page.
- Fix: Prevent "are you sure" message that has started occuring from WordPress when saving a WordPress form
- Fix: Correctly validate form fields with an Inside field label when HTML5 forms are not enabled
- Fix: Set the background color on loading form submit button. Depending on the hover button covers, the loading spinner may have been the same color as the button
- Fix: Additional security checks when getting POST or GET values in some places
- Fix: Return int rather than string from FrmForm::getIdByKey
- Pro Version Forms
- New: Allow normal WordPress shortcodes in the field calculations box
- Fix: Strip commas during form validation in non-HTML5 number fields
- Fix: Correctly order the views dropdown in the shortcode builder
Download this release
Release Info
Developer | sswells |
Plugin | Formidable Forms – Form Builder for WordPress |
Version | 2.05.04 |
Comparing to | |
See all releases |
Code changes from version 2.05.03 to 2.05.04
- classes/controllers/FrmAppController.php +5 -4
- classes/controllers/FrmFormsController.php +1 -1
- classes/controllers/FrmHooksController.php +1 -1
- classes/controllers/FrmStylesController.php +16 -3
- classes/helpers/FrmAppHelper.php +3 -2
- classes/helpers/FrmFieldsHelper.php +1 -1
- classes/helpers/FrmFormsHelper.php +2 -2
- classes/helpers/FrmXMLHelper.php +1 -1
- classes/models/FrmEntryValidate.php +18 -2
- classes/models/FrmForm.php +4 -5
- classes/views/frm-entries/form.php +1 -1
- classes/views/styles/custom_css.php +12 -2
- classes/views/xml/default-templates.xml +0 -26
- css/_single_theme.css.php +1 -0
- formidable.php +1 -1
- js/formidable_admin.js +12 -0
- readme.txt +16 -3
classes/controllers/FrmAppController.php
CHANGED
@@ -291,10 +291,11 @@ class FrmAppController {
|
|
291 |
/**
|
292 |
* Filter shortcodes in text widgets
|
293 |
*/
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
|
|
298 |
|
299 |
/**
|
300 |
* Deprecated in favor of wpmu_upgrade_site
|
291 |
/**
|
292 |
* Filter shortcodes in text widgets
|
293 |
*/
|
294 |
+
public static function widget_text_filter( $content ) {
|
295 |
+
_deprecated_function( __METHOD__, '2.5.4' );
|
296 |
+
$regex = '/\[\s*(formidable|display-frm-data|frm-stats|frm-graph|frm-entry-links|formresults|frm-search)\s+.*\]/';
|
297 |
+
return preg_replace_callback( $regex, 'FrmAppHelper::widget_text_filter_callback', $content );
|
298 |
+
}
|
299 |
|
300 |
/**
|
301 |
* Deprecated in favor of wpmu_upgrade_site
|
classes/controllers/FrmFormsController.php
CHANGED
@@ -815,7 +815,7 @@ class FrmFormsController {
|
|
815 |
$bulkaction = str_replace( 'bulk_', '', $bulkaction );
|
816 |
}
|
817 |
|
818 |
-
|
819 |
if ( empty( $ids ) ) {
|
820 |
$errors[] = __( 'No forms were specified', 'formidable' );
|
821 |
return $errors;
|
815 |
$bulkaction = str_replace( 'bulk_', '', $bulkaction );
|
816 |
}
|
817 |
|
818 |
+
$ids = FrmAppHelper::get_param( 'item-action', '', 'get', 'sanitize_text_field' );
|
819 |
if ( empty( $ids ) ) {
|
820 |
$errors[] = __( 'No forms were specified', 'formidable' );
|
821 |
return $errors;
|
classes/controllers/FrmHooksController.php
CHANGED
@@ -49,7 +49,7 @@ class FrmHooksController {
|
|
49 |
}
|
50 |
|
51 |
add_action( 'plugins_loaded', 'FrmAppController::load_lang' );
|
52 |
-
|
53 |
|
54 |
// Entries controller
|
55 |
add_action( 'wp_loaded', 'FrmEntriesController::process_entry', 10, 0 );
|
49 |
}
|
50 |
|
51 |
add_action( 'plugins_loaded', 'FrmAppController::load_lang' );
|
52 |
+
add_filter( 'widget_text', 'do_shortcode' );
|
53 |
|
54 |
// Entries controller
|
55 |
add_action( 'wp_loaded', 'FrmEntriesController::process_entry', 10, 0 );
|
classes/controllers/FrmStylesController.php
CHANGED
@@ -267,9 +267,22 @@ class FrmStylesController {
|
|
267 |
}
|
268 |
|
269 |
public static function custom_css( $message = '', $style = null ) {
|
270 |
-
|
271 |
-
|
272 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
273 |
|
274 |
if ( ! isset($style) ) {
|
275 |
$frm_style = new FrmStyle();
|
267 |
}
|
268 |
|
269 |
public static function custom_css( $message = '', $style = null ) {
|
270 |
+
if ( function_exists('wp_enqueue_code_editor') ) {
|
271 |
+
$id = 'frm_codemirror_box';
|
272 |
+
$settings = wp_enqueue_code_editor( array(
|
273 |
+
'type' => 'text/css',
|
274 |
+
'codemirror' => array(
|
275 |
+
'indentUnit' => 2,
|
276 |
+
'tabSize' => 2,
|
277 |
+
),
|
278 |
+
) );
|
279 |
+
} else {
|
280 |
+
$id = 'frm_custom_css_box';
|
281 |
+
$settings = array();
|
282 |
+
wp_enqueue_style('codemirror', FrmAppHelper::plugin_url() . '/css/codemirror.css');
|
283 |
+
wp_enqueue_script('codemirror', FrmAppHelper::plugin_url() . '/js/codemirror/codemirror.js', array(), '4.7');
|
284 |
+
wp_enqueue_script( 'codemirror-css', FrmAppHelper::plugin_url() . '/js/codemirror/css.js', array( 'codemirror' ), '4.7' );
|
285 |
+
}
|
286 |
|
287 |
if ( ! isset($style) ) {
|
288 |
$frm_style = new FrmStyle();
|
classes/helpers/FrmAppHelper.php
CHANGED
@@ -4,13 +4,13 @@ if ( ! defined('ABSPATH') ) {
|
|
4 |
}
|
5 |
|
6 |
class FrmAppHelper {
|
7 |
-
public static $db_version =
|
8 |
public static $pro_db_version = 37; //deprecated
|
9 |
|
10 |
/**
|
11 |
* @since 2.0
|
12 |
*/
|
13 |
-
public static $plug_version = '2.05.
|
14 |
|
15 |
/**
|
16 |
* @since 1.07.02
|
@@ -639,6 +639,7 @@ class FrmAppHelper {
|
|
639 |
* Used to filter shortcode in text widgets
|
640 |
*/
|
641 |
public static function widget_text_filter_callback( $matches ) {
|
|
|
642 |
return do_shortcode( $matches[0] );
|
643 |
}
|
644 |
|
4 |
}
|
5 |
|
6 |
class FrmAppHelper {
|
7 |
+
public static $db_version = 47; //version of the database we are moving to
|
8 |
public static $pro_db_version = 37; //deprecated
|
9 |
|
10 |
/**
|
11 |
* @since 2.0
|
12 |
*/
|
13 |
+
public static $plug_version = '2.05.04';
|
14 |
|
15 |
/**
|
16 |
* @since 1.07.02
|
639 |
* Used to filter shortcode in text widgets
|
640 |
*/
|
641 |
public static function widget_text_filter_callback( $matches ) {
|
642 |
+
_deprecated_function( __METHOD__, '2.5.4' );
|
643 |
return do_shortcode( $matches[0] );
|
644 |
}
|
645 |
|
classes/helpers/FrmFieldsHelper.php
CHANGED
@@ -865,7 +865,7 @@ DEFAULT_HTML;
|
|
865 |
$atts['param'] = str_replace(']', ']', $atts['param']);
|
866 |
}
|
867 |
|
868 |
-
|
869 |
$new_value = FrmAppHelper::get_query_var( $new_value, $atts['param'] );
|
870 |
|
871 |
if ( $new_value == '' ) {
|
865 |
$atts['param'] = str_replace(']', ']', $atts['param']);
|
866 |
}
|
867 |
|
868 |
+
$new_value = FrmAppHelper::get_param( $atts['param'], '', 'get', 'sanitize_text_field' );
|
869 |
$new_value = FrmAppHelper::get_query_var( $new_value, $atts['param'] );
|
870 |
|
871 |
if ( $new_value == '' ) {
|
classes/helpers/FrmFormsHelper.php
CHANGED
@@ -163,7 +163,7 @@ class FrmFormsHelper {
|
|
163 |
|
164 |
foreach ( array( 'name' => '', 'description' => '' ) as $var => $default ) {
|
165 |
if ( ! isset( $values[ $var ] ) ) {
|
166 |
-
$values[ $var ] = FrmAppHelper::get_param( $var, $default );
|
167 |
}
|
168 |
}
|
169 |
|
@@ -171,7 +171,7 @@ class FrmFormsHelper {
|
|
171 |
|
172 |
foreach ( array( 'form_id' => '', 'logged_in' => '', 'editable' => '', 'default_template' => 0, 'is_template' => 0, 'status' => 'draft', 'parent_form_id' => 0 ) as $var => $default ) {
|
173 |
if ( ! isset( $values[ $var ] ) ) {
|
174 |
-
$values[ $var ] = FrmAppHelper::get_param( $var, $default );
|
175 |
}
|
176 |
}
|
177 |
|
163 |
|
164 |
foreach ( array( 'name' => '', 'description' => '' ) as $var => $default ) {
|
165 |
if ( ! isset( $values[ $var ] ) ) {
|
166 |
+
$values[ $var ] = FrmAppHelper::get_param( $var, $default, 'get', 'sanitize_text_field' );
|
167 |
}
|
168 |
}
|
169 |
|
171 |
|
172 |
foreach ( array( 'form_id' => '', 'logged_in' => '', 'editable' => '', 'default_template' => 0, 'is_template' => 0, 'status' => 'draft', 'parent_form_id' => 0 ) as $var => $default ) {
|
173 |
if ( ! isset( $values[ $var ] ) ) {
|
174 |
+
$values[ $var ] = FrmAppHelper::get_param( $var, $default, 'get', 'sanitize_text_field' );
|
175 |
}
|
176 |
}
|
177 |
|
classes/helpers/FrmXMLHelper.php
CHANGED
@@ -797,7 +797,7 @@ class FrmXMLHelper {
|
|
797 |
}
|
798 |
|
799 |
if ( ! is_array($result) ) {
|
800 |
-
$message = is_string( $result ) ? $result : print_r( $result, 1 );
|
801 |
return;
|
802 |
}
|
803 |
|
797 |
}
|
798 |
|
799 |
if ( ! is_array($result) ) {
|
800 |
+
$message = is_string( $result ) ? $result : htmlentities( print_r( $result, 1 ) );
|
801 |
return;
|
802 |
}
|
803 |
|
classes/models/FrmEntryValidate.php
CHANGED
@@ -105,7 +105,19 @@ class FrmEntryValidate {
|
|
105 |
}
|
106 |
|
107 |
private static function maybe_clear_value_for_default_blank_setting( $field, &$value ) {
|
108 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
109 |
$value = '';
|
110 |
}
|
111 |
}
|
@@ -139,12 +151,16 @@ class FrmEntryValidate {
|
|
139 |
}
|
140 |
}
|
141 |
|
142 |
-
public static function validate_number_field( &$errors, $field,
|
143 |
//validate the number format
|
144 |
if ( $field->type != 'number' ) {
|
145 |
return;
|
146 |
}
|
147 |
|
|
|
|
|
|
|
|
|
148 |
if ( ! is_numeric( $value) ) {
|
149 |
$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $field, 'invalid' );
|
150 |
}
|
105 |
}
|
106 |
|
107 |
private static function maybe_clear_value_for_default_blank_setting( $field, &$value ) {
|
108 |
+
$is_default = ( FrmField::is_option_true_in_object( $field, 'default_blank' ) && $value == $field->default_value );
|
109 |
+
$is_label = false;
|
110 |
+
|
111 |
+
if ( ! $is_default ) {
|
112 |
+
$position = FrmField::get_option( $field, 'label' );
|
113 |
+
if ( empty( $position ) ) {
|
114 |
+
$position = FrmStylesController::get_style_val( 'position', $field->form_id );
|
115 |
+
}
|
116 |
+
|
117 |
+
$is_label = ( $position == 'inside' && FrmFieldsHelper::is_placeholder_field_type( $field->type ) && $value == $field->name );
|
118 |
+
}
|
119 |
+
|
120 |
+
if ( $is_label || $is_default ) {
|
121 |
$value = '';
|
122 |
}
|
123 |
}
|
151 |
}
|
152 |
}
|
153 |
|
154 |
+
public static function validate_number_field( &$errors, $field, &$value, $args ) {
|
155 |
//validate the number format
|
156 |
if ( $field->type != 'number' ) {
|
157 |
return;
|
158 |
}
|
159 |
|
160 |
+
if ( strpos( $value, ',' ) ) {
|
161 |
+
$value = str_replace( ',', '', $value );
|
162 |
+
}
|
163 |
+
|
164 |
if ( ! is_numeric( $value) ) {
|
165 |
$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $field, 'invalid' );
|
166 |
}
|
classes/models/FrmForm.php
CHANGED
@@ -446,8 +446,7 @@ class FrmForm {
|
|
446 |
* @return int form id
|
447 |
*/
|
448 |
public static function getIdByKey( $key ) {
|
449 |
-
|
450 |
-
return $id;
|
451 |
}
|
452 |
|
453 |
/**
|
@@ -655,7 +654,7 @@ class FrmForm {
|
|
655 |
if ( $var == 'action' ) {
|
656 |
$values[ $var ] = FrmAppHelper::get_param( $action_var, $default, 'get', 'sanitize_title' );
|
657 |
} else {
|
658 |
-
$values[ $var ] = FrmAppHelper::get_param( $var, $default );
|
659 |
}
|
660 |
unset( $var, $default );
|
661 |
}
|
@@ -676,7 +675,7 @@ class FrmForm {
|
|
676 |
public static function list_page_params() {
|
677 |
$values = array();
|
678 |
foreach ( array( 'template' => 0, 'id' => '', 'paged' => 1, 'form' => '', 'search' => '', 'sort' => '', 'sdir' => '' ) as $var => $default ) {
|
679 |
-
$values[ $var ] = FrmAppHelper::get_param( $var, $default );
|
680 |
}
|
681 |
|
682 |
return $values;
|
@@ -696,7 +695,7 @@ class FrmForm {
|
|
696 |
'field_id' => '', 'search' => '', 'sort' => '', 'sdir' => '', 'fid' => '',
|
697 |
'keep_post' => '',
|
698 |
) as $var => $default ) {
|
699 |
-
$values[ $var ] = FrmAppHelper::get_param( $var, $default );
|
700 |
}
|
701 |
|
702 |
return $values;
|
446 |
* @return int form id
|
447 |
*/
|
448 |
public static function getIdByKey( $key ) {
|
449 |
+
return (int) FrmDb::get_var( 'frm_forms', array( 'form_key' => sanitize_title( $key ) ) );
|
|
|
450 |
}
|
451 |
|
452 |
/**
|
654 |
if ( $var == 'action' ) {
|
655 |
$values[ $var ] = FrmAppHelper::get_param( $action_var, $default, 'get', 'sanitize_title' );
|
656 |
} else {
|
657 |
+
$values[ $var ] = FrmAppHelper::get_param( $var, $default, 'get', 'sanitize_text_field' );
|
658 |
}
|
659 |
unset( $var, $default );
|
660 |
}
|
675 |
public static function list_page_params() {
|
676 |
$values = array();
|
677 |
foreach ( array( 'template' => 0, 'id' => '', 'paged' => 1, 'form' => '', 'search' => '', 'sort' => '', 'sdir' => '' ) as $var => $default ) {
|
678 |
+
$values[ $var ] = FrmAppHelper::get_param( $var, $default, 'get', 'sanitize_text_field' );
|
679 |
}
|
680 |
|
681 |
return $values;
|
695 |
'field_id' => '', 'search' => '', 'sort' => '', 'sdir' => '', 'fid' => '',
|
696 |
'keep_post' => '',
|
697 |
) as $var => $default ) {
|
698 |
+
$values[ $var ] = FrmAppHelper::get_param( $var, $default, 'get', 'sanitize_text_field' );
|
699 |
}
|
700 |
|
701 |
return $values;
|
classes/views/frm-entries/form.php
CHANGED
@@ -25,7 +25,7 @@ $frm_hide_fields = FrmAppHelper::get_post_param( 'frm_hide_fields_' . $form->id,
|
|
25 |
<input type="hidden" name="form_key" value="<?php echo esc_attr($form->form_key) ?>" />
|
26 |
<input type="hidden" name="item_meta[0]" value="" />
|
27 |
<?php wp_nonce_field( 'frm_submit_entry_nonce', 'frm_submit_entry_' . $form->id ); ?>
|
28 |
-
<input type="text" class="frm_hidden frm_verify" id="frm_verify_<?php echo esc_attr( $form->id ) ?>" name="frm_verify" value="<?php echo esc_attr( FrmAppHelper::get_param('frm_verify' ) ) ?>" <?php FrmFormsHelper::maybe_hide_inline() ?> />
|
29 |
|
30 |
<?php if ( isset( $id ) ) { ?><input type="hidden" name="id" value="<?php echo esc_attr( $id ) ?>" /><?php }
|
31 |
|
25 |
<input type="hidden" name="form_key" value="<?php echo esc_attr($form->form_key) ?>" />
|
26 |
<input type="hidden" name="item_meta[0]" value="" />
|
27 |
<?php wp_nonce_field( 'frm_submit_entry_nonce', 'frm_submit_entry_' . $form->id ); ?>
|
28 |
+
<input type="text" class="frm_hidden frm_verify" id="frm_verify_<?php echo esc_attr( $form->id ) ?>" name="frm_verify" value="<?php echo esc_attr( FrmAppHelper::get_param('frm_verify', '', 'get', 'wp_kses_post' ) ) ?>" <?php FrmFormsHelper::maybe_hide_inline() ?> />
|
29 |
|
30 |
<?php if ( isset( $id ) ) { ?><input type="hidden" name="id" value="<?php echo esc_attr( $id ) ?>" /><?php }
|
31 |
|
classes/views/styles/custom_css.php
CHANGED
@@ -14,9 +14,19 @@
|
|
14 |
<input type="hidden" name="frm_action" value="save_css" />
|
15 |
<?php wp_nonce_field( 'frm_custom_css_nonce', 'frm_custom_css' ); ?>
|
16 |
|
17 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
18 |
|
19 |
-
<?php
|
20 |
foreach ( $style->post_content as $k => $v ) {
|
21 |
if ( $k == 'custom_css' ) {
|
22 |
continue;
|
14 |
<input type="hidden" name="frm_action" value="save_css" />
|
15 |
<?php wp_nonce_field( 'frm_custom_css_nonce', 'frm_custom_css' ); ?>
|
16 |
|
17 |
+
<textarea name="<?php echo esc_attr( $frm_style->get_field_name('custom_css') ) ?>" id="<?php echo esc_attr( $id ) ?>" class="hide-if-js"><?php echo FrmAppHelper::esc_textarea( $style->post_content['custom_css'] ) ?></textarea>
|
18 |
+
|
19 |
+
<?php
|
20 |
+
if ( ! empty( $settings ) && $id == 'frm_codemirror_box' ) {
|
21 |
+
wp_add_inline_script(
|
22 |
+
'code-editor',
|
23 |
+
sprintf(
|
24 |
+
'jQuery( function() { wp.codeEditor.initialize( "' . esc_attr( $id ) . '", %s ); } );',
|
25 |
+
wp_json_encode( $settings )
|
26 |
+
)
|
27 |
+
);
|
28 |
+
}
|
29 |
|
|
|
30 |
foreach ( $style->post_content as $k => $v ) {
|
31 |
if ( $k == 'custom_css' ) {
|
32 |
continue;
|
classes/views/xml/default-templates.xml
CHANGED
@@ -52,19 +52,6 @@
|
|
52 |
<required>1</required>
|
53 |
<options><![CDATA[]]></options>
|
54 |
<field_options><![CDATA[{"blank":"","invalid":"Please enter a valid email address","classes":"frm_full"}]]></field_options>
|
55 |
-
</field>
|
56 |
-
<field>
|
57 |
-
<id>4</id>
|
58 |
-
<field_key><![CDATA[itt5me]]></field_key>
|
59 |
-
<name><![CDATA[Website]]></name>
|
60 |
-
<description><![CDATA[]]></description>
|
61 |
-
<type><![CDATA[url]]></type>
|
62 |
-
<default_value><![CDATA[]]></default_value>
|
63 |
-
<field_order>4</field_order>
|
64 |
-
<form_id>1</form_id>
|
65 |
-
<required></required>
|
66 |
-
<options><![CDATA[]]></options>
|
67 |
-
<field_options><![CDATA[{"blank":"","invalid":"Please enter a valid website","classes":"frm_full"}]]></field_options>
|
68 |
</field>
|
69 |
<field>
|
70 |
<id>5</id>
|
@@ -92,19 +79,6 @@
|
|
92 |
<options><![CDATA[]]></options>
|
93 |
<field_options><![CDATA[{"max":"5","blank":"","classes":"frm_full"}]]></field_options>
|
94 |
</field>
|
95 |
-
<field>
|
96 |
-
<id>7</id>
|
97 |
-
<field_key><![CDATA[62n6q3]]></field_key>
|
98 |
-
<name><![CDATA[Captcha]]></name>
|
99 |
-
<description><![CDATA[]]></description>
|
100 |
-
<type><![CDATA[captcha]]></type>
|
101 |
-
<default_value><![CDATA[]]></default_value>
|
102 |
-
<field_order>7</field_order>
|
103 |
-
<form_id>1</form_id>
|
104 |
-
<required></required>
|
105 |
-
<options><![CDATA[]]></options>
|
106 |
-
<field_options><![CDATA[{"label":"none","blank":"","clear_on_focus":0,"default_blank":0}]]></field_options>
|
107 |
-
</field>
|
108 |
</form>
|
109 |
<view>
|
110 |
<title>Email Notification</title>
|
52 |
<required>1</required>
|
53 |
<options><![CDATA[]]></options>
|
54 |
<field_options><![CDATA[{"blank":"","invalid":"Please enter a valid email address","classes":"frm_full"}]]></field_options>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
55 |
</field>
|
56 |
<field>
|
57 |
<id>5</id>
|
79 |
<options><![CDATA[]]></options>
|
80 |
<field_options><![CDATA[{"max":"5","blank":"","classes":"frm_full"}]]></field_options>
|
81 |
</field>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
82 |
</form>
|
83 |
<view>
|
84 |
<title>Email Notification</title>
|
css/_single_theme.css.php
CHANGED
@@ -590,6 +590,7 @@ if ( ! $submit_style ) { ?>
|
|
590 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:active,
|
591 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:focus{
|
592 |
color: transparent <?php echo esc_html( $important ) ?>;
|
|
|
593 |
}
|
594 |
|
595 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:before {
|
590 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:active,
|
591 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:focus{
|
592 |
color: transparent <?php echo esc_html( $important ) ?>;
|
593 |
+
background: <?php echo esc_html( $submit_bg_color . $important ) ?>;
|
594 |
}
|
595 |
|
596 |
.<?php echo esc_html( $style_class ) ?> .frm_loading_form .frm_button_submit:before {
|
formidable.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
Plugin Name: Formidable Forms
|
4 |
Description: Quickly and easily create drag-and-drop forms
|
5 |
-
Version: 2.05.
|
6 |
Plugin URI: https://formidableforms.com/
|
7 |
Author URI: https://formidableforms.com/
|
8 |
Author: Strategy11
|
2 |
/*
|
3 |
Plugin Name: Formidable Forms
|
4 |
Description: Quickly and easily create drag-and-drop forms
|
5 |
+
Version: 2.05.04
|
6 |
Plugin URI: https://formidableforms.com/
|
7 |
Author URI: https://formidableforms.com/
|
8 |
Author: Strategy11
|
js/formidable_admin.js
CHANGED
@@ -1381,6 +1381,7 @@ function frmAdminBuildJS(){
|
|
1381 |
}
|
1382 |
|
1383 |
function preFormSave(b){
|
|
|
1384 |
if(jQuery('form.inplace_form').length){
|
1385 |
jQuery('.inplace_save, .postbox').click();
|
1386 |
}
|
@@ -2351,6 +2352,13 @@ function frmAdminBuildJS(){
|
|
2351 |
}
|
2352 |
}
|
2353 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2354 |
return{
|
2355 |
init: function(){
|
2356 |
window.onscroll = document.documentElement.onscroll = setMenuOffset;
|
@@ -2460,6 +2468,9 @@ function frmAdminBuildJS(){
|
|
2460 |
|
2461 |
jQuery(document.getElementById('frm_deauthorize_link')).click(deauthorize);
|
2462 |
jQuery('.frm_authorize_link').click(authorize);
|
|
|
|
|
|
|
2463 |
},
|
2464 |
|
2465 |
buildInit: function(){
|
@@ -2890,6 +2901,7 @@ function frmAdminBuildJS(){
|
|
2890 |
},
|
2891 |
|
2892 |
customCSSInit: function() {
|
|
|
2893 |
var customCSS = document.getElementById('frm_custom_css_box');
|
2894 |
if ( customCSS !== null ) {
|
2895 |
var editor = CodeMirror.fromTextArea(customCSS, {
|
1381 |
}
|
1382 |
|
1383 |
function preFormSave(b){
|
1384 |
+
removeWPUnload();
|
1385 |
if(jQuery('form.inplace_form').length){
|
1386 |
jQuery('.inplace_save, .postbox').click();
|
1387 |
}
|
2352 |
}
|
2353 |
}
|
2354 |
|
2355 |
+
function removeWPUnload() {
|
2356 |
+
window.onbeforeunload = null;
|
2357 |
+
var w = jQuery( window );
|
2358 |
+
w.off( 'beforeunload.widgets' );
|
2359 |
+
w.off( 'beforeunload.edit-post' );
|
2360 |
+
}
|
2361 |
+
|
2362 |
return{
|
2363 |
init: function(){
|
2364 |
window.onscroll = document.documentElement.onscroll = setMenuOffset;
|
2468 |
|
2469 |
jQuery(document.getElementById('frm_deauthorize_link')).click(deauthorize);
|
2470 |
jQuery('.frm_authorize_link').click(authorize);
|
2471 |
+
|
2472 |
+
// prevent annoying confirmation message from WordPress
|
2473 |
+
jQuery('button').on('click', removeWPUnload);
|
2474 |
},
|
2475 |
|
2476 |
buildInit: function(){
|
2901 |
},
|
2902 |
|
2903 |
customCSSInit: function() {
|
2904 |
+
/* deprecated since WP 4.9 */
|
2905 |
var customCSS = document.getElementById('frm_custom_css_box');
|
2906 |
if ( customCSS !== null ) {
|
2907 |
var editor = CodeMirror.fromTextArea(customCSS, {
|
readme.txt
CHANGED
@@ -2,9 +2,9 @@
|
|
2 |
Contributors: formidableforms, sswells, srwells, jamie.wahlin
|
3 |
Tags: contact form, form builder, custom form, forms, form, form maker, form creator
|
4 |
Requires at least: 4.0
|
5 |
-
Tested up to: 4.
|
6 |
-
Requires PHP: 5.
|
7 |
-
Stable tag: 2.05.
|
8 |
|
9 |
The best WordPress form plugin for contact forms, surveys and more. Make forms a breeze with a drag and drop form builder and form style generator.
|
10 |
|
@@ -145,6 +145,19 @@ The field and form names and descriptions are all changed with in-place edit. Ju
|
|
145 |
[See more FAQs](https://formidableforms.com/formidable-faqs/ "Formidable Form FAQs")
|
146 |
|
147 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
148 |
= 2.05.03 =
|
149 |
* Enhancement: Clean up BCC and CC email buttons on small screens
|
150 |
* Security enhancement: Use wp_kses instead of wp_kses_post for showing entries
|
2 |
Contributors: formidableforms, sswells, srwells, jamie.wahlin
|
3 |
Tags: contact form, form builder, custom form, forms, form, form maker, form creator
|
4 |
Requires at least: 4.0
|
5 |
+
Tested up to: 4.9
|
6 |
+
Requires PHP: 5.3
|
7 |
+
Stable tag: 2.05.04
|
8 |
|
9 |
The best WordPress form plugin for contact forms, surveys and more. Make forms a breeze with a drag and drop form builder and form style generator.
|
10 |
|
145 |
[See more FAQs](https://formidableforms.com/formidable-faqs/ "Formidable Form FAQs")
|
146 |
|
147 |
== Changelog ==
|
148 |
+
= 2.05.04 =
|
149 |
+
* Tweak: Remove recaptcha and website fields from sample Contact us form template since most people don't need them
|
150 |
+
* Fix: Updates for WP 4.9 compatibility. This includes preventing double filtering on contact form widgets and using the WordPress Codemirror scripts for the form CSS page.
|
151 |
+
* Fix: Prevent "are you sure" message that has started occuring from WordPress when saving a WordPress form
|
152 |
+
* Fix: Correctly validate form fields with an Inside field label when HTML5 forms are not enabled
|
153 |
+
* Fix: Set the background color on loading form submit button. Depending on the hover button covers, the loading spinner may have been the same color as the button
|
154 |
+
* Fix: Additional security checks when getting POST or GET values in some places
|
155 |
+
* Fix: Return int rather than string from FrmForm::getIdByKey
|
156 |
+
* **Pro Version Forms**
|
157 |
+
* New: Allow normal WordPress shortcodes in the field calculations box
|
158 |
+
* Fix: Strip commas during form validation in non-HTML5 number fields
|
159 |
+
* Fix: Correctly order the views dropdown in the shortcode builder
|
160 |
+
|
161 |
= 2.05.03 =
|
162 |
* Enhancement: Clean up BCC and CC email buttons on small screens
|
163 |
* Security enhancement: Use wp_kses instead of wp_kses_post for showing entries
|