Custom Contact Forms - Version 3.5.8

Version Description

  • custom-contact-forms-db.php - Table cache added and columnExists function redone to fix compadibility issues
Download this release

Release Info

Developer tlovett1
Plugin Icon 128x128 Custom Contact Forms
Version 3.5.8
Comparing to
See all releases

Code changes from version 3.5.7 to 3.5.8

custom-contact-forms-db.php CHANGED
@@ -10,6 +10,7 @@ if (!class_exists('CustomContactFormsDB')) {
10
  var $fields_table;
11
  var $styles_table;
12
  var $field_options_table;
 
13
  function CustomContactFormsDB() {
14
  global $wpdb;
15
  $table_prefix = $wpdb->prefix;
@@ -164,10 +165,24 @@ if (!class_exists('CustomContactFormsDB')) {
164
 
165
  }
166
 
167
- function columnExists($column, $table) {
168
  global $wpdb;
169
  $tests = $wpdb->get_results("SELECT * FROM INFORMATION_SCHEMA.columns WHERE table_name = '$table' AND column_name = '$column' LIMIT 0 , 30");
170
  return (!empty($test[0]) && $test[0]->COLUMN_NAME == $column);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
171
  }
172
 
173
  function insertForm($form) {
10
  var $fields_table;
11
  var $styles_table;
12
  var $field_options_table;
13
+ var $cache = array();
14
  function CustomContactFormsDB() {
15
  global $wpdb;
16
  $table_prefix = $wpdb->prefix;
165
 
166
  }
167
 
168
+ /*function columnExists($column, $table) {
169
  global $wpdb;
170
  $tests = $wpdb->get_results("SELECT * FROM INFORMATION_SCHEMA.columns WHERE table_name = '$table' AND column_name = '$column' LIMIT 0 , 30");
171
  return (!empty($test[0]) && $test[0]->COLUMN_NAME == $column);
172
+ }*/
173
+
174
+ function columnExists($column, $table) {
175
+ global $wpdb;
176
+ if (!is_array($this->cache[$table]))
177
+ $this->cache[$table] = array();
178
+ if (empty($this->cache[$table][columns]))
179
+ $this->cache[$table][columns] = $wpdb->get_results('SHOW COLUMNS FROM ' . $table, ARRAY_A);
180
+ $col_array = $this->cache[$table][columns];
181
+ foreach ($col_array as $col) {
182
+ if ($col[Field] == $column)
183
+ return true;
184
+ }
185
+ return false;
186
  }
187
 
188
  function insertForm($form) {
custom-contact-forms.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Custom Contact Forms
4
  Plugin URI: http://taylorlovett.com/wordpress-plugins
5
  Description: Guaranteed to be 1000X more customizable and intuitive than Fast Secure Contact Forms or Contact Form 7. Customize every aspect of your forms without any knowledge of CSS: borders, padding, sizes, colors. Ton's of great features. Required fields, captchas, tooltip popovers, unlimited fields/forms/form styles, use a custom thank you page or built-in popover with a custom success message set for each form. <a href="options-general.php?page=custom-contact-forms">Settings</a>
6
- Version: 3.5.7
7
  Author: Taylor Lovett
8
  Author URI: http://www.taylorlovett.com
9
  */
3
  Plugin Name: Custom Contact Forms
4
  Plugin URI: http://taylorlovett.com/wordpress-plugins
5
  Description: Guaranteed to be 1000X more customizable and intuitive than Fast Secure Contact Forms or Contact Form 7. Customize every aspect of your forms without any knowledge of CSS: borders, padding, sizes, colors. Ton's of great features. Required fields, captchas, tooltip popovers, unlimited fields/forms/form styles, use a custom thank you page or built-in popover with a custom success message set for each form. <a href="options-general.php?page=custom-contact-forms">Settings</a>
6
+ Version: 3.5.8
7
  Author: Taylor Lovett
8
  Author URI: http://www.taylorlovett.com
9
  */
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.taylorlovett.com
4
  Tags: contact form, web form, custom contact form, custom forms, captcha form, contact fields, form mailers
5
  Requires at least: 2.8.1
6
  Tested up to: 3.0.1
7
- Stable tag: 3.5.7
8
 
9
  Gauranteed to be the most customizable and intuitive contact form plugin for Wordpress.
10
 
@@ -76,6 +76,9 @@ Visit http://www.taylorlovett.com/wordpress-plugins for screenshots. Right now a
76
 
77
  == Changelog ==
78
 
 
 
 
79
  = 3.5.7 =
80
  * custom-contact-forms.php - fixed home page form redirect bug
81
  * css/custom-contact-forms-admin.css - manager tables restyled
4
  Tags: contact form, web form, custom contact form, custom forms, captcha form, contact fields, form mailers
5
  Requires at least: 2.8.1
6
  Tested up to: 3.0.1
7
+ Stable tag: 3.5.8
8
 
9
  Gauranteed to be the most customizable and intuitive contact form plugin for Wordpress.
10
 
76
 
77
  == Changelog ==
78
 
79
+ = 3.5.8 =
80
+ * custom-contact-forms-db.php - Table cache added and columnExists function redone to fix compadibility issues
81
+
82
  = 3.5.7 =
83
  * custom-contact-forms.php - fixed home page form redirect bug
84
  * css/custom-contact-forms-admin.css - manager tables restyled