Version Description
- Fix to captcha image and db encoding
=
Download this release
Release Info
Developer | codepeople |
Plugin | Payment Form for PayPal Pro |
Version | 1.1.57 |
Comparing to | |
See all releases |
Code changes from version 1.1.56 to 1.1.57
- README.txt +5 -2
- captcha/captcha.php +2 -2
- cp_ppp.php +1 -1
- cp_ppp_admin_int_list.inc.php +2 -2
README.txt
CHANGED
@@ -299,7 +299,10 @@ A: In all plugin versions you can turn off IP tracking to avoid saving that user
|
|
299 |
= 1.1.56 =
|
300 |
* Code improvements
|
301 |
|
|
|
|
|
|
|
302 |
== Upgrade Notice ==
|
303 |
|
304 |
-
= 1.1.
|
305 |
-
*
|
299 |
= 1.1.56 =
|
300 |
* Code improvements
|
301 |
|
302 |
+
= 1.1.57 =
|
303 |
+
* Fix to captcha image and db encoding
|
304 |
+
|
305 |
== Upgrade Notice ==
|
306 |
|
307 |
+
= 1.1.57 =
|
308 |
+
* Fix to captcha image and db encoding
|
captcha/captcha.php
CHANGED
@@ -62,9 +62,9 @@ $length = 0;
|
|
62 |
for ($i = 0; $i < $letter_count; $i++) {
|
63 |
$str .= chr(mt_rand(97, 122))." ";
|
64 |
}
|
65 |
-
$_SESSION['rand_code'
|
66 |
|
67 |
-
setCookie('rand_code'
|
68 |
|
69 |
$image = imagecreatetruecolor($imgX, $imgY);
|
70 |
$backgr_col = imagecolorallocate($image, $bcolor["r"],$bcolor["g"],$bcolor["b"]);
|
62 |
for ($i = 0; $i < $letter_count; $i++) {
|
63 |
$str .= chr(mt_rand(97, 122))." ";
|
64 |
}
|
65 |
+
$_SESSION['rand_code'.sanitize_key($_GET["ps"])] = str_replace(" ", "", $str);
|
66 |
|
67 |
+
setCookie('rand_code'.sanitize_key($_GET["ps"]), md5(str_replace(" ", "", $str)), time()+36000,"/");
|
68 |
|
69 |
$image = imagecreatetruecolor($imgX, $imgY);
|
70 |
$backgr_col = imagecolorallocate($image, $bcolor["r"],$bcolor["g"],$bcolor["b"]);
|
cp_ppp.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Payment Form for PayPal Pro
|
4 |
Plugin URI: https://wordpress.dwbooster.com/forms/paypal-payment-pro-form
|
5 |
Description: Payment Form for PayPal Pro to accept credit cards directly into your website. Official PayPal Partner.
|
6 |
-
Version: 1.1.
|
7 |
Author: CodePeople
|
8 |
Author URI: https://wordpress.dwbooster.com/forms/payment-form-for-paypal-pro
|
9 |
License: GPL
|
3 |
Plugin Name: Payment Form for PayPal Pro
|
4 |
Plugin URI: https://wordpress.dwbooster.com/forms/paypal-payment-pro-form
|
5 |
Description: Payment Form for PayPal Pro to accept credit cards directly into your website. Official PayPal Partner.
|
6 |
+
Version: 1.1.57
|
7 |
Author: CodePeople
|
8 |
Author URI: https://wordpress.dwbooster.com/forms/payment-form-for-paypal-pro
|
9 |
License: GPL
|
cp_ppp_admin_int_list.inc.php
CHANGED
@@ -101,7 +101,7 @@ else if (isset($_GET['ac']) && $_GET['ac'] == 'st' && $current_user_access && wp
|
|
101 |
update_option( 'CP_CFPP_LOAD_SCRIPTS_ADMIN', ($_GET["scradmin"]=="1"?"0":"1") );
|
102 |
if ($_GET["chs"] != '')
|
103 |
{
|
104 |
-
$target_charset =
|
105 |
$tables = array( $wpdb->prefix.CP_PPP_POSTS_TABLE_NAME_NO_PREFIX, $wpdb->prefix.CP_PPP_FORMS_TABLE );
|
106 |
foreach ($tables as $tab)
|
107 |
{
|
@@ -112,7 +112,7 @@ else if (isset($_GET['ac']) && $_GET['ac'] == 'st' && $current_user_access && wp
|
|
112 |
$type = $item->Type;
|
113 |
if (preg_match("/^varchar\((\d+)\)$/i", $type, $mat) || !strcasecmp($type, "CHAR") || !strcasecmp($type, "TEXT") || !strcasecmp($type, "MEDIUMTEXT"))
|
114 |
{
|
115 |
-
$wpdb->query("ALTER TABLE {$tab} CHANGE {$name} {$name} {$type} COLLATE {$target_charset}");
|
116 |
}
|
117 |
}
|
118 |
}
|
101 |
update_option( 'CP_CFPP_LOAD_SCRIPTS_ADMIN', ($_GET["scradmin"]=="1"?"0":"1") );
|
102 |
if ($_GET["chs"] != '')
|
103 |
{
|
104 |
+
$target_charset = str_replace('`','``',sanitize_text_field($_GET["chs"]));
|
105 |
$tables = array( $wpdb->prefix.CP_PPP_POSTS_TABLE_NAME_NO_PREFIX, $wpdb->prefix.CP_PPP_FORMS_TABLE );
|
106 |
foreach ($tables as $tab)
|
107 |
{
|
112 |
$type = $item->Type;
|
113 |
if (preg_match("/^varchar\((\d+)\)$/i", $type, $mat) || !strcasecmp($type, "CHAR") || !strcasecmp($type, "TEXT") || !strcasecmp($type, "MEDIUMTEXT"))
|
114 |
{
|
115 |
+
$wpdb->query("ALTER TABLE {$tab} CHANGE {$name} {$name} {$type} COLLATE `{$target_charset}`");
|
116 |
}
|
117 |
}
|
118 |
}
|