Payment Form for PayPal Pro - Version 1.0.3

Version Description

  • Tested and compatible with WordPress 4.4
  • Fixed parameter value in saving settings process.

=

Download this release

Release Info

Developer codepeople
Plugin Icon 128x128 Payment Form for PayPal Pro
Version 1.0.3
Comparing to
See all releases

Code changes from version 1.0.2 to 1.0.3

Files changed (3) hide show
  1. README.txt +8 -3
  2. captcha/captcha.php +1 -1
  3. cp_ppp.php +8 -8
README.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: codepeople
3
Donate link: http://wordpress.dwbooster.com/forms/paypal-payment-pro-form
4
Tags: paypal,paypal pro,paypal advanced,pro,accept,credit,cards,card,payment,processing
5
Requires at least: 3.0.5
6
- Tested up to: 4.2
7
Stable tag: trunk
8
License: GPLv2 or later
9
License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -165,7 +165,12 @@ If that doesn't work please check if your hosting service requires some specific
165
= 1.0.2 =
166
* XSS vulnerability fixed
167
168
== Upgrade Notice ==
169
170
- = 1.0.2 =
171
- * XSS vulnerability fixed
3
Donate link: http://wordpress.dwbooster.com/forms/paypal-payment-pro-form
4
Tags: paypal,paypal pro,paypal advanced,pro,accept,credit,cards,card,payment,processing
5
Requires at least: 3.0.5
6
+ Tested up to: 4.4
7
Stable tag: trunk
8
License: GPLv2 or later
9
License URI: http://www.gnu.org/licenses/gpl-2.0.html
165
= 1.0.2 =
166
* XSS vulnerability fixed
167
168
+ = 1.0.3 =
169
+ * Tested and compatible with WordPress 4.4
170
+ * Fixed parameter value in saving settings process.
171
+
172
== Upgrade Notice ==
173
174
+ = 1.0.3 =
175
+ * Tested and compatible with WordPress 4.4
176
+ * Fixed parameter value in saving settings process.
captcha/captcha.php CHANGED
@@ -76,7 +76,7 @@ function cpcff_similarColors($c1, $c2)
76
// USAGE
77
// if (empty($_POST['hdcaptcha']) || $_POST['hdcaptcha'] != $_SESSION['rand_code']) header("Location: /form.html");
78
79
- session_start();
80
81
function cpcff_make_seed() {
82
list($usec, $sec) = explode(' ', microtime());
76
// USAGE
77
// if (empty($_POST['hdcaptcha']) || $_POST['hdcaptcha'] != $_SESSION['rand_code']) header("Location: /form.html");
78
79
+ if (function_exists('session_start')) @session_start();
80
81
function cpcff_make_seed() {
82
list($usec, $sec) = explode(' ', microtime());
cp_ppp.php CHANGED
@@ -3,7 +3,7 @@
3
Plugin Name: Payment Form for PayPal Pro
4
Plugin URI: http://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.0.2
7
Author: CodePeople.net
8
Author URI: http://codepeople.net
9
License: GPL
@@ -137,7 +137,7 @@ function cp_ppp_install($networkwide) {
137
if ($networkwide) {
138
$old_blog = $wpdb->blogid;
139
// Get all blog ids
140
- $blogids = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM $wpdb->blogs"));
141
foreach ($blogids as $blog_id) {
142
switch_to_blog($blog_id);
143
_cp_ppp_install();
@@ -438,7 +438,7 @@ function cp_ppp_get_public_form($id) {
438
if ($id != '')
439
$myrows = $wpdb->get_results( $wpdb->prepare("SELECT * FROM ".$wpdb->prefix.CP_PPP_FORMS_TABLE." WHERE id=%d", $id) );
440
else
441
- $myrows = $wpdb->get_results( $wpdb->prepare("SELECT * FROM ".$wpdb->prefix.CP_PPP_FORMS_TABLE, array()) );
442
443
$previous_label = cp_ppp_get_option('vs_text_previousbtn', 'Previous',$id);
444
$previous_label = ($previous_label==''?'Previous':$previous_label);
@@ -744,7 +744,7 @@ function cp_ppp_check_posted_data() {
744
if (isset($_GET["cp_ppp_id"])) $_POST["cp_ppp_id"] = intval($_GET["cp_ppp_id"]);
745
if (isset($_POST["cp_ppp_id"])) define("CP_PPP_ID",intval($_POST["cp_ppp_id"]));
746
747
- @session_start();
748
if (isset($_GET["ps"])) $sequence = $_GET["ps"]; else if (isset($_POST["cp_pform_psequence"])) $sequence = $_POST["cp_pform_psequence"];
749
if (!isset($_GET['hdcaptcha_cp_ppp_post']) || $_GET['hdcaptcha_cp_ppp_post'] == '') $_GET['hdcaptcha_cp_ppp_post'] = @$_POST['hdcaptcha_cp_ppp_post'];
750
if (
@@ -907,7 +907,7 @@ function cp_ppp_check_posted_data() {
907
$rows_affected = $wpdb->insert( CP_PPP_POSTS_TABLE_NAME, array( 'formid' => CP_PPP_ID,
908
'time' => current_time('mysql'),
909
'ipaddr' => $_SERVER['REMOTE_ADDR'],
910
- 'notifyto' => @$_POST[$to],
911
'paypal_post' => serialize($params),
912
'posted_data' => serialize($params),
913
'data' =>$buffer_A .($coupon?"\n\nCoupon code:".$coupon->code.$discount_note:"")
@@ -1330,7 +1330,7 @@ function cp_ppp_save_options()
1330
'paypalpro_api_password' => $_POST["paypalpro_api_password"],
1331
'paypalpro_api_signature' => $_POST["paypalpro_api_signature"],
1332
1333
- 'cp_user_access' => serialize($_POST["cp_user_access"]),
1334
1335
'enable_paypal_option_yes' => (@$_POST['enable_paypal_option_yes']?$_POST['enable_paypal_option_yes']:CP_PPP_PAYPAL_OPTION_YES),
1336
'enable_paypal_option_no' => (@$_POST['enable_paypal_option_no']?$_POST['enable_paypal_option_no']:CP_PPP_PAYPAL_OPTION_NO),
@@ -1401,10 +1401,10 @@ function cp_ppp_get_option ($field, $default_value, $id = '')
1401
1402
class CP_PPP_Widget extends WP_Widget
1403
{
1404
- function CP_PPP_Widget()
1405
{
1406
$widget_ops = array('classname' => 'CP_PPP_Widget', 'description' => 'Displays a form integrated with Paypal' );
1407
- $this->WP_Widget('CP_PPP_Widget', 'Payment Form for PayPal Pro', $widget_ops);
1408
}
1409
1410
function form($instance)
3
Plugin Name: Payment Form for PayPal Pro
4
Plugin URI: http://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.0.3
7
Author: CodePeople.net
8
Author URI: http://codepeople.net
9
License: GPL
137
if ($networkwide) {
138
$old_blog = $wpdb->blogid;
139
// Get all blog ids
140
+ $blogids = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs");
141
foreach ($blogids as $blog_id) {
142
switch_to_blog($blog_id);
143
_cp_ppp_install();
438
if ($id != '')
439
$myrows = $wpdb->get_results( $wpdb->prepare("SELECT * FROM ".$wpdb->prefix.CP_PPP_FORMS_TABLE." WHERE id=%d", $id) );
440
else
441
+ $myrows = $wpdb->get_results( "SELECT * FROM ".$wpdb->prefix.CP_PPP_FORMS_TABLE );
442
443
$previous_label = cp_ppp_get_option('vs_text_previousbtn', 'Previous',$id);
444
$previous_label = ($previous_label==''?'Previous':$previous_label);
744
if (isset($_GET["cp_ppp_id"])) $_POST["cp_ppp_id"] = intval($_GET["cp_ppp_id"]);
745
if (isset($_POST["cp_ppp_id"])) define("CP_PPP_ID",intval($_POST["cp_ppp_id"]));
746
747
+ if (function_exists('session_start')) @session_start();
748
if (isset($_GET["ps"])) $sequence = $_GET["ps"]; else if (isset($_POST["cp_pform_psequence"])) $sequence = $_POST["cp_pform_psequence"];
749
if (!isset($_GET['hdcaptcha_cp_ppp_post']) || $_GET['hdcaptcha_cp_ppp_post'] == '') $_GET['hdcaptcha_cp_ppp_post'] = @$_POST['hdcaptcha_cp_ppp_post'];
750
if (
907
$rows_affected = $wpdb->insert( CP_PPP_POSTS_TABLE_NAME, array( 'formid' => CP_PPP_ID,
908
'time' => current_time('mysql'),
909
'ipaddr' => $_SERVER['REMOTE_ADDR'],
910
+ 'notifyto' => (@$_POST[$to]?$_POST[$to]:''),
911
'paypal_post' => serialize($params),
912
'posted_data' => serialize($params),
913
'data' =>$buffer_A .($coupon?"\n\nCoupon code:".$coupon->code.$discount_note:"")
1330
'paypalpro_api_password' => $_POST["paypalpro_api_password"],
1331
'paypalpro_api_signature' => $_POST["paypalpro_api_signature"],
1332
1333
+ 'cp_user_access' => serialize(@$_POST["cp_user_access"]),
1334
1335
'enable_paypal_option_yes' => (@$_POST['enable_paypal_option_yes']?$_POST['enable_paypal_option_yes']:CP_PPP_PAYPAL_OPTION_YES),
1336
'enable_paypal_option_no' => (@$_POST['enable_paypal_option_no']?$_POST['enable_paypal_option_no']:CP_PPP_PAYPAL_OPTION_NO),
1401
1402
class CP_PPP_Widget extends WP_Widget
1403
{
1404
+ function __construct()
1405
{
1406
$widget_ops = array('classname' => 'CP_PPP_Widget', 'description' => 'Displays a form integrated with Paypal' );
1407
+ parent::__construct('CP_PPP_Widget', 'Payment Form for PayPal Pro', $widget_ops);
1408
}
1409
1410
function form($instance)