Contact Bank: WordPress Form Builder for Contact Forms - Version 2.0.119

Version Description

  • Few Bugs Fixed
  • Changed Variables to avoid conflictions with other plugins.
Download this release

Release Info

Developer contact-banker
Plugin Icon 128x128 Contact Bank: WordPress Form Builder for Contact Forms
Version 2.0.119
Comparing to
See all releases

Code changes from version 2.0.118 to 2.0.119

contact-bank.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Contact Bank Lite Edition
4
  Plugin URI: http://tech-banker.com
5
  Description: Build Complex, Powerful Contact Forms in Just Seconds. No Programming Knowledge Required! Yeah, It's Really That Easy.
6
  Author: Tech Banker
7
- Version: 2.0.118
8
  Author URI: http://tech-banker.com
9
  License: GPLv3 or later
10
  */
@@ -1148,11 +1148,13 @@ function plugin_load_textdomain_contact_bank_services()
1148
  }
1149
  add_action("plugins_loaded", "plugin_load_textdomain_contact_bank_services");
1150
  $version = get_option("contact-bank-version-number");
1151
- if($version != "")
1152
  {
1153
- add_action('admin_init', 'plugin_install_script_for_contact_bank');
 
 
 
1154
  }
1155
-
1156
  function contact_bank_plugin_row($links,$file)
1157
  {
1158
  if ($file == CONTACT_BK_PLUGIN_BASENAME)
@@ -1165,6 +1167,28 @@ function contact_bank_plugin_row($links,$file)
1165
  }
1166
  return (array)$links;
1167
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1168
  //--------------------------------------------------------------------------------------------------------------//
1169
  // CODE FOR PLUGIN UPDATE MESSAGE
1170
  //--------------------------------------------------------------------------------------------------------------//
4
  Plugin URI: http://tech-banker.com
5
  Description: Build Complex, Powerful Contact Forms in Just Seconds. No Programming Knowledge Required! Yeah, It's Really That Easy.
6
  Author: Tech Banker
7
+ Version: 2.0.119
8
  Author URI: http://tech-banker.com
9
  License: GPLv3 or later
10
  */
1148
  }
1149
  add_action("plugins_loaded", "plugin_load_textdomain_contact_bank_services");
1150
  $version = get_option("contact-bank-version-number");
1151
+ if (is_admin() && !request_is_frontend_ajax())
1152
  {
1153
+ if($version != "")
1154
+ {
1155
+ add_action("admin_init", "plugin_install_script_for_contact_bank");
1156
+ }
1157
  }
 
1158
  function contact_bank_plugin_row($links,$file)
1159
  {
1160
  if ($file == CONTACT_BK_PLUGIN_BASENAME)
1167
  }
1168
  return (array)$links;
1169
  }
1170
+ function request_is_frontend_ajax()
1171
+ {
1172
+ $script_filename = isset($_SERVER['SCRIPT_FILENAME']) ? $_SERVER['SCRIPT_FILENAME'] : '';
1173
+
1174
+ //Try to figure out if frontend AJAX request... If we are DOING_AJAX; let's look closer
1175
+ if((defined('DOING_AJAX') && DOING_AJAX))
1176
+ {
1177
+ //From wp-includes/functions.php, wp_get_referer() function.
1178
+ //Required to fix: https://core.trac.wordpress.org/ticket/25294
1179
+ $ref = '';
1180
+ if ( ! empty( $_REQUEST['_wp_http_referer'] ) )
1181
+ $ref = wp_unslash( $_REQUEST['_wp_http_referer'] );
1182
+ elseif ( ! empty( $_SERVER['HTTP_REFERER'] ) )
1183
+ $ref = wp_unslash( $_SERVER['HTTP_REFERER'] );
1184
+ //If referer does not contain admin URL and we are using the admin-ajax.php endpoint, this is likely a frontend AJAX request
1185
+ if(((strpos($ref, admin_url()) === false) && (basename($script_filename) === 'admin-ajax.php')))
1186
+ return true;
1187
+ }
1188
+
1189
+ //If no checks triggered, we end up here - not an AJAX request.
1190
+ return false;
1191
+ }
1192
  //--------------------------------------------------------------------------------------------------------------//
1193
  // CODE FOR PLUGIN UPDATE MESSAGE
1194
  //--------------------------------------------------------------------------------------------------------------//
frontend_views/contact_bank_forms.php CHANGED
@@ -458,7 +458,7 @@ $rand_value = RAND(10,10000);
458
  }
459
  ?>
460
  <div class="layout-control-group">
461
- <button type="submit" class="btn_submit"><?php _e($layout_settings_array[$form_id]["submit_button_text"],contact_bank);?></button>
462
  </div>
463
  </form>
464
  </div>
458
  }
459
  ?>
460
  <div class="layout-control-group">
461
+ <button type="submit" class="btn_submit"><?php _e(trim($layout_settings_array[$form_id]["submit_button_text"]),contact_bank);?></button>
462
  </div>
463
  </form>
464
  </div>
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: contact-banker, Gallery-Bank
3
  Tags: admin, advanced form, Attachment, best contact form plugin, buddypress, category, cnotact, conact, contact, contact button, contact form, contact form builder, Contact Form Builder with recaptcha, contact form manager, contact form plugin, contact form with google map, contact forms, contact forms plugin, contact manager, contact me, contact us, contact us form, contacts, contacts form plugin, contatc, copy, custom form, email, email form, feedback, feedback form, feedback forms, form, forms, forms plugin, insert the shortcode, multiple contact forms, post feedback, request, send, send copy, send messages, shortcode, text, web form, web-page feedback, wordpress contact form
4
  Requires at least: 3.3
5
  Tested up to: 4.2.2
6
- Stable tag: 2.0.118
7
  License: GPLv3 or later
8
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
9
 
@@ -549,6 +549,11 @@ In order to set Shortcode for a Form, you need to follow these steps :
549
 
550
  == Changelog ==
551
 
 
 
 
 
 
552
  = 2.0.118 =
553
 
554
  * Few Minor CSS Bugs Fixed
3
  Tags: admin, advanced form, Attachment, best contact form plugin, buddypress, category, cnotact, conact, contact, contact button, contact form, contact form builder, Contact Form Builder with recaptcha, contact form manager, contact form plugin, contact form with google map, contact forms, contact forms plugin, contact manager, contact me, contact us, contact us form, contacts, contacts form plugin, contatc, copy, custom form, email, email form, feedback, feedback form, feedback forms, form, forms, forms plugin, insert the shortcode, multiple contact forms, post feedback, request, send, send copy, send messages, shortcode, text, web form, web-page feedback, wordpress contact form
4
  Requires at least: 3.3
5
  Tested up to: 4.2.2
6
+ Stable tag: 2.0.119
7
  License: GPLv3 or later
8
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
9
 
549
 
550
  == Changelog ==
551
 
552
+ = 2.0.119 =
553
+
554
+ * Few Bugs Fixed
555
+ * Changed Variables to avoid conflictions with other plugins.
556
+
557
  = 2.0.118 =
558
 
559
  * Few Minor CSS Bugs Fixed