diff --git a/lib/PayPal/Rest/RestHandler.php b/lib/PayPal/Rest/RestHandler.php index 8ec134c..364aaf7 100644 --- a/lib/PayPal/Rest/RestHandler.php +++ b/lib/PayPal/Rest/RestHandler.php @@ -38,7 +38,7 @@ class RestHandler implements IPPHandler * * @var string $sdkVersion */ - public static $sdkVersion = "0.6.0"; + public static $sdkVersion = "0.13.2"; /** * Construct diff --git a/phpunit.xml b/phpunit.xml index d298fb2..039146f 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -23,8 +23,6 @@ - @@ -35,4 +33,4 @@ - \ No newline at end of file + diff --git a/release_notes.md b/release_notes.md index f2510d7..a283dfd 100644 --- a/release_notes.md +++ b/release_notes.md @@ -1,6 +1,11 @@ PayPal PHP SDK release notes ============================ +v0.13.2 +---- +* Updated Future Payments and LIPP Support +* Updated Logging Syntax + v0.13.1 ---- * Enabled TLS version 1.x for SSL Negotiation diff --git a/sample/common.php b/sample/common.php index 4f00959..a623ac6 100644 --- a/sample/common.php +++ b/sample/common.php @@ -24,7 +24,7 @@ function print_result($title, $objectName, $objectId = null, $output = null) if ($output) { if (is_a($output, 'PayPal\Common\PPModel')) { /** @var $output \PayPal\Common\PPModel */ - echo "
" . $output->toJSON(JSON_PRETTY_PRINT) . "
"; + echo "
" . $output->toJSON(128) . "
"; } elseif (is_string($output)) { echo "
$output
"; } diff --git a/sample/doc/invoice/CancelInvoice.html b/sample/doc/invoice/CancelInvoice.html index a644001..8ea3eed 100644 --- a/sample/doc/invoice/CancelInvoice.html +++ b/sample/doc/invoice/CancelInvoice.html @@ -38,7 +38,7 @@ notification object </head> <body> <div>Cancel Invoice:</div> -<pre><?php echo $invoice->toJSON(JSON_PRETTY_PRINT); ?></pre> +<pre><?php echo $invoice->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/invoice/CreateInvoice.html b/sample/doc/invoice/CreateInvoice.html index 1c43f39..2b57627 100644 --- a/sample/doc/invoice/CreateInvoice.html +++ b/sample/doc/invoice/CreateInvoice.html @@ -89,7 +89,7 @@ with a valid ApiContext (See bootstrap.php for more on ApiContext)< Created Invoice: <?php echo $invoice->getId(); ?> </div> -<pre><?php echo $invoice->toJSON(JSON_PRETTY_PRINT); ?></pre> +<pre><?php echo $invoice->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/invoice/GetInvoice.html b/sample/doc/invoice/GetInvoice.html index cb78d85..e59de18 100644 --- a/sample/doc/invoice/GetInvoice.html +++ b/sample/doc/invoice/GetInvoice.html @@ -22,7 +22,7 @@ Invoice ID </head> <body> <div>Retrieving Invoice: <?php echo $invoiceId;?></div> - <pre><?php echo $invoice->toJSON(JSON_PRETTY_PRINT); ?></pre> + <pre><?php echo $invoice->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/invoice/ListInvoice.html b/sample/doc/invoice/ListInvoice.html index af7d80d..14acc2b 100644 --- a/sample/doc/invoice/ListInvoice.html +++ b/sample/doc/invoice/ListInvoice.html @@ -20,7 +20,7 @@ Refer the method doc for valid values for keys </head> <body> <div>Got invoices </div> - <pre><?php echo $invoices->toJSON(JSON_PRETTY_PRINT); ?></pre> + <pre><?php echo $invoices->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/invoice/RemindInvoice.html b/sample/doc/invoice/RemindInvoice.html index fc2a4ae..14e717d 100644 --- a/sample/doc/invoice/RemindInvoice.html +++ b/sample/doc/invoice/RemindInvoice.html @@ -37,7 +37,7 @@ notification object </head> <body> <div>Remind Invoice:</div> -<pre><?php echo $invoice->toJSON(JSON_PRETTY_PRINT); ?></pre> +<pre><?php echo $invoice->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/invoice/SendInvoice.html b/sample/doc/invoice/SendInvoice.html index e93baac..9c87077 100644 --- a/sample/doc/invoice/SendInvoice.html +++ b/sample/doc/invoice/SendInvoice.html @@ -25,7 +25,7 @@ with a valid ApiContext (See bootstrap.php for more on ApiContext)< </head> <body> <div>Send Invoice:</div> -<pre><?php echo $invoice->toJSON(JSON_PRETTY_PRINT); ?></pre> +<pre><?php echo $invoice->toJSON(128); ?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/lipp/GetUserInfo.html b/sample/doc/lipp/GetUserInfo.html index 3c83cc1..131e602 100644 --- a/sample/doc/lipp/GetUserInfo.html +++ b/sample/doc/lipp/GetUserInfo.html @@ -22,4 +22,4 @@ to retreive the information. The short lived access token can be retrieved using exit(1); } -print_result("User Information", "User Info", $userInfo->getUserId(), $userInfo->toJSON(JSON_PRETTY_PRINT)); \ No newline at end of file +print_result("User Information", "User Info", $userInfo->getUserId(), $userInfo->toJSON(128)); diff --git a/sample/doc/payment-experience/ListWebProfiles.html b/sample/doc/payment-experience/ListWebProfiles.html index b6c5e82..3dc01ae 100644 --- a/sample/doc/payment-experience/ListWebProfiles.html +++ b/sample/doc/payment-experience/ListWebProfiles.html @@ -15,9 +15,9 @@ static get_list method on the WebProfile class. } $result = ''; foreach ($list as $object) { - $result .= $object->toJSON(JSON_PRETTY_PRINT) . PHP_EOL; + $result .= $object->toJSON(128) . PHP_EOL; } print_result("Get List of All Web Profiles", "Web Profiles", null, $result); -return $list; \ No newline at end of file +return $list; diff --git a/sample/doc/payments/AuthorizationCapture.html b/sample/doc/payments/AuthorizationCapture.html index 8616eda..e1adff5 100644 --- a/sample/doc/payments/AuthorizationCapture.html +++ b/sample/doc/payments/AuthorizationCapture.html @@ -33,7 +33,7 @@ createAuthorization defined in common.php

<?php echo $getCapture->getParentPayment(); ?>. Capture Id: <?php echo $getCapture->getId();?> </div> - <pre><?php echo $getCapture->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $getCapture->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/CreateFuturePayment.html b/sample/doc/payments/CreateFuturePayment.html index b60ebff..dcd2ee5 100644 --- a/sample/doc/payments/CreateFuturePayment.html +++ b/sample/doc/payments/CreateFuturePayment.html @@ -61,7 +61,7 @@ Please note that currently future payments works only with PayPal as a funding i Created payment: <?php echo $payment->getId();?> </div> -<pre><?php echo $payment->toJSON(JSON_PRETTY_PRINT);?></pre> +<pre><?php echo $payment->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/payments/CreatePayment.html b/sample/doc/payments/CreatePayment.html index 775bcd4..6812541 100644 --- a/sample/doc/payments/CreatePayment.html +++ b/sample/doc/payments/CreatePayment.html @@ -91,7 +91,7 @@ The return object contains the state.

<?php echo $payment->getId();?> </div> - <pre><?php echo $payment->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $payment->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/CreatePaymentUsingSavedCard.html b/sample/doc/payments/CreatePaymentUsingSavedCard.html index bec2a1f..d63a18e 100644 --- a/sample/doc/payments/CreatePaymentUsingSavedCard.html +++ b/sample/doc/payments/CreatePaymentUsingSavedCard.html @@ -80,7 +80,7 @@ The return object contains the state.

<?php echo $payment->getId();?> </div> - <pre><?php echo $payment->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $payment->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/ExecutePayment.html b/sample/doc/payments/ExecutePayment.html index 92a84bd..221287d 100644 --- a/sample/doc/payments/ExecutePayment.html +++ b/sample/doc/payments/ExecutePayment.html @@ -23,11 +23,11 @@ when the user is redirected from paypal back to your site

//Execute the payment

(See bootstrap.php for more on ApiContext)

$result = $payment->execute($execution, $apiContext); echo "<html><body><pre>"; - echo $result->toJSON(JSON_PRETTY_PRINT); + echo $result->toJSON(128); echo "</pre><a href='../index.html'>Back</a></body></html>"; } else { echo "<html><body><h1>"; echo "User cancelled payment."; echo "</h1><a href='../index.html'>Back</a></body></html>"; -}
\ No newline at end of file +} diff --git a/sample/doc/payments/GetAuthorization.html b/sample/doc/payments/GetAuthorization.html index 9d5a287..3836bd0 100644 --- a/sample/doc/payments/GetAuthorization.html +++ b/sample/doc/payments/GetAuthorization.html @@ -25,7 +25,7 @@ createAuthorization is defined in common.php

<?php echo $authorization->getId();?> </div> - <pre><?php echo $authorization->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $authorization->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/GetCapture.html b/sample/doc/payments/GetCapture.html index 3a56b1b..8aae25d 100644 --- a/sample/doc/payments/GetCapture.html +++ b/sample/doc/payments/GetCapture.html @@ -41,7 +41,7 @@ with a valid ApiContext (See bootstrap.php for more on ApiContext)< Capture Id: <?php echo $capture->getId();?> </div> - <pre><?php echo $capture->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $capture->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/payments/GetPayment.html b/sample/doc/payments/GetPayment.html index 45ed0d6..82a25df 100644 --- a/sample/doc/payments/GetPayment.html +++ b/sample/doc/payments/GetPayment.html @@ -27,7 +27,7 @@ Payment ID </head> <body> <div>Retrieving Payment ID: <?php echo $paymentId;?></div> - <pre><?php echo $payment->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $payment->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/payments/ListPayments.html b/sample/doc/payments/ListPayments.html index 3caf078..97352dc 100644 --- a/sample/doc/payments/ListPayments.html +++ b/sample/doc/payments/ListPayments.html @@ -26,7 +26,7 @@ Refer the method doc for valid values for keys </head> <body> <div>Got <?php echo $payments->getCount(); ?> matching payments </div> - <pre><?php echo $payments->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $payments->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/payments/Reauthorization.html b/sample/doc/payments/Reauthorization.html index 72004dc..cde56f5 100644 --- a/sample/doc/payments/Reauthorization.html +++ b/sample/doc/payments/Reauthorization.html @@ -30,8 +30,8 @@ has expired.

<?php echo $reauthorization->getId();?> </div> <pre> - <?php echo $reauthorization->toJSON(JSON_PRETTY_PRINT);?> + <?php echo $reauthorization->toJSON(128);?> </pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/RefundCapture.html b/sample/doc/payments/RefundCapture.html index c74e0b9..dd84a19 100644 --- a/sample/doc/payments/RefundCapture.html +++ b/sample/doc/payments/RefundCapture.html @@ -46,7 +46,7 @@ PayPal-Request-Id (idempotency) header for this resource

<?php echo $captureRefund->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $captureRefund->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/payments/VoidAuthorization.html b/sample/doc/payments/VoidAuthorization.html index af14468..f9b48fa 100644 --- a/sample/doc/payments/VoidAuthorization.html +++ b/sample/doc/payments/VoidAuthorization.html @@ -22,7 +22,7 @@ createAuthorization is defined in common.php

<?php echo $voidedAuth->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $voidedAuth->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/sale/GetSale.html b/sample/doc/sale/GetSale.html index 1ef8ebd..9872fd4 100644 --- a/sample/doc/sale/GetSale.html +++ b/sample/doc/sale/GetSale.html @@ -22,7 +22,7 @@ transaction from your payment resource.

<?php echo $saleId;?></div> - <pre><?php echo $sale->toJSON(JSON_PRETTY_PRINT)?></pre> + <pre><?php echo $sale->toJSON(128)?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/sale/RefundSale.html b/sample/doc/sale/RefundSale.html index 9adfae0..e3999fb 100644 --- a/sample/doc/sale/RefundSale.html +++ b/sample/doc/sale/RefundSale.html @@ -32,7 +32,7 @@ given sale transaction id.

<?php echo $saleId;?></div> - <pre><?php echo $sale->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $sale->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/doc/vault/CreateCreditCard.html b/sample/doc/vault/CreateCreditCard.html index 8220c4f..6b006c4 100644 --- a/sample/doc/vault/CreateCreditCard.html +++ b/sample/doc/vault/CreateCreditCard.html @@ -31,7 +31,7 @@ in future payments. </head> <body> <div>Saved a new credit card with id: <?php echo $card->getId();?></div> - <pre><?php echo $card->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $card->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html> \ No newline at end of file +</html> diff --git a/sample/doc/vault/GetCreditCard.html b/sample/doc/vault/GetCreditCard.html index 0856d8a..91d46d2 100644 --- a/sample/doc/vault/GetCreditCard.html +++ b/sample/doc/vault/GetCreditCard.html @@ -21,7 +21,7 @@ card operation. Use $card->getId()

<?php echo $cardId;?></div> - <pre><?php echo $card->toJSON(JSON_PRETTY_PRINT);?></pre> + <pre><?php echo $card->toJSON(128);?></pre> <a href='../index.html'>Back</a> </body> -</html>
\ No newline at end of file +</html> diff --git a/sample/invoice/CancelInvoice.php b/sample/invoice/CancelInvoice.php index 493adc1..8480ed8 100644 --- a/sample/invoice/CancelInvoice.php +++ b/sample/invoice/CancelInvoice.php @@ -51,7 +51,7 @@ try {
Cancel Invoice:
-
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/invoice/CreateInvoice.php b/sample/invoice/CreateInvoice.php index 0cb4c0e..eaa17ca 100644 --- a/sample/invoice/CreateInvoice.php +++ b/sample/invoice/CreateInvoice.php @@ -113,7 +113,7 @@ try { Created Invoice: getId(); ?> -
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/invoice/GetInvoice.php b/sample/invoice/GetInvoice.php index 256f516..6c64017 100644 --- a/sample/invoice/GetInvoice.php +++ b/sample/invoice/GetInvoice.php @@ -29,7 +29,7 @@ try {
Retrieving Invoice:
-
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/invoice/ListInvoice.php b/sample/invoice/ListInvoice.php index 9f69ffe..b4e5dd3 100644 --- a/sample/invoice/ListInvoice.php +++ b/sample/invoice/ListInvoice.php @@ -26,7 +26,7 @@ try {
Got invoices
-
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/invoice/RemindInvoice.php b/sample/invoice/RemindInvoice.php index fa5796f..b3d79a1 100644 --- a/sample/invoice/RemindInvoice.php +++ b/sample/invoice/RemindInvoice.php @@ -49,7 +49,7 @@ try {
Remind Invoice:
-
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/invoice/SendInvoice.php b/sample/invoice/SendInvoice.php index bc5f937..2b314b3 100644 --- a/sample/invoice/SendInvoice.php +++ b/sample/invoice/SendInvoice.php @@ -34,7 +34,7 @@ try {
Send Invoice:
-
toJSON(JSON_PRETTY_PRINT); ?>
+
toJSON(128); ?>
Back diff --git a/sample/lipp/GetUserInfo.php b/sample/lipp/GetUserInfo.php index 34c74f8..f63f830 100644 --- a/sample/lipp/GetUserInfo.php +++ b/sample/lipp/GetUserInfo.php @@ -34,4 +34,4 @@ try { exit(1); } -print_result("User Information", "User Info", $userInfo->getUserId(), $userInfo->toJSON(JSON_PRETTY_PRINT)); +print_result("User Information", "User Info", $userInfo->getUserId(), $userInfo->toJSON(128)); diff --git a/sample/payment-experience/ListWebProfiles.php b/sample/payment-experience/ListWebProfiles.php index 641fd1d..d4794b7 100644 --- a/sample/payment-experience/ListWebProfiles.php +++ b/sample/payment-experience/ListWebProfiles.php @@ -20,7 +20,7 @@ try { } $result = ''; foreach ($list as $object) { - $result .= $object->toJSON(JSON_PRETTY_PRINT) . PHP_EOL; + $result .= $object->toJSON(128) . PHP_EOL; } print_result("Get List of All Web Profiles", "Web Profiles", null, $result); diff --git a/sample/payments/AuthorizationCapture.php b/sample/payments/AuthorizationCapture.php index 6e3c7b8..b1e3db2 100644 --- a/sample/payments/AuthorizationCapture.php +++ b/sample/payments/AuthorizationCapture.php @@ -48,7 +48,7 @@ try { Captured payment getParentPayment(); ?>. Capture Id: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/CreateFuturePayment.php b/sample/payments/CreateFuturePayment.php index 674caf4..c3bfbfd 100644 --- a/sample/payments/CreateFuturePayment.php +++ b/sample/payments/CreateFuturePayment.php @@ -96,7 +96,7 @@ try { Created payment: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/CreatePayment.php b/sample/payments/CreatePayment.php index 9cfa1cb..2df81ad 100644 --- a/sample/payments/CreatePayment.php +++ b/sample/payments/CreatePayment.php @@ -123,7 +123,7 @@ try { Created payment: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/CreatePaymentUsingSavedCard.php b/sample/payments/CreatePaymentUsingSavedCard.php index 344401b..556230d 100644 --- a/sample/payments/CreatePaymentUsingSavedCard.php +++ b/sample/payments/CreatePaymentUsingSavedCard.php @@ -111,7 +111,7 @@ try { Created payment: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/ExecutePayment.php b/sample/payments/ExecutePayment.php index dba78f5..3edae33 100644 --- a/sample/payments/ExecutePayment.php +++ b/sample/payments/ExecutePayment.php @@ -32,7 +32,7 @@ if(isset($_GET['success']) && $_GET['success'] == 'true') { $result = $payment->execute($execution, $apiContext); echo "
";
-	echo $result->toJSON(JSON_PRETTY_PRINT);
+	echo $result->toJSON(128);
 	echo "
Back"; } else { diff --git a/sample/payments/GetAuthorization.php b/sample/payments/GetAuthorization.php index f66bb85..bf5c9cf 100644 --- a/sample/payments/GetAuthorization.php +++ b/sample/payments/GetAuthorization.php @@ -37,7 +37,7 @@ try { Retrieved Authorization: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/GetCapture.php b/sample/payments/GetCapture.php index d470dbd..ed1c9c4 100644 --- a/sample/payments/GetCapture.php +++ b/sample/payments/GetCapture.php @@ -58,7 +58,7 @@ try { Capture Id: getId();?> -
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/GetPayment.php b/sample/payments/GetPayment.php index 5d81d93..abea03c 100644 --- a/sample/payments/GetPayment.php +++ b/sample/payments/GetPayment.php @@ -33,7 +33,7 @@ try {
Retrieving Payment ID:
-
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/ListPayments.php b/sample/payments/ListPayments.php index a588613..6bcde85 100644 --- a/sample/payments/ListPayments.php +++ b/sample/payments/ListPayments.php @@ -1,40 +1,40 @@ - 10, 'start_index' => 5), $apiContext); -} catch (PayPal\Exception\PPConnectionException $ex) { - echo "Exception:" . $ex->getMessage() . PHP_EOL; - var_dump($ex->getData()); - exit(1); -} -?> - - - Lookup payment history - - -
Got getCount(); ?> matching payments
-
toJSON(JSON_PRETTY_PRINT);?>
- Back - - + 10, 'start_index' => 5), $apiContext); +} catch (PayPal\Exception\PPConnectionException $ex) { + echo "Exception:" . $ex->getMessage() . PHP_EOL; + var_dump($ex->getData()); + exit(1); +} +?> + + + Lookup payment history + + +
Got getCount(); ?> matching payments
+
toJSON(128);?>
+ Back + + diff --git a/sample/payments/Reauthorization.php b/sample/payments/Reauthorization.php index 02a5ac0..a0318dc 100644 --- a/sample/payments/Reauthorization.php +++ b/sample/payments/Reauthorization.php @@ -44,7 +44,7 @@ try { getId();?>
-		toJSON(JSON_PRETTY_PRINT);?>
+		toJSON(128);?>
 	
Back diff --git a/sample/payments/RefundCapture.php b/sample/payments/RefundCapture.php index 07c6427..8dfe4cd 100644 --- a/sample/payments/RefundCapture.php +++ b/sample/payments/RefundCapture.php @@ -64,7 +64,7 @@ try {
Refund Capture:
-
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/payments/VoidAuthorization.php b/sample/payments/VoidAuthorization.php index 974c6bb..563bf22 100644 --- a/sample/payments/VoidAuthorization.php +++ b/sample/payments/VoidAuthorization.php @@ -37,7 +37,7 @@ try {
Voided authorization
-
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/sale/GetSale.php b/sample/sale/GetSale.php index 0c8aece..4e0d4d6 100644 --- a/sample/sale/GetSale.php +++ b/sample/sale/GetSale.php @@ -1,34 +1,34 @@ -getMessage() . PHP_EOL; - var_dump($ex->getData()); - exit(1); -} -?> - - - Lookup a sale - - -
Retrieving sale id:
-
toJSON(JSON_PRETTY_PRINT)?>
- Back - - +getMessage() . PHP_EOL; + var_dump($ex->getData()); + exit(1); +} +?> + + + Lookup a sale + + +
Retrieving sale id:
+
toJSON(128)?>
+ Back + + diff --git a/sample/sale/RefundSale.php b/sample/sale/RefundSale.php index 6b734ce..93be6fd 100644 --- a/sample/sale/RefundSale.php +++ b/sample/sale/RefundSale.php @@ -1,53 +1,53 @@ -details -// field to mention fees refund details. -$amt = new Amount(); -$amt->setCurrency('USD') - ->setTotal('0.01'); - -// ### Refund object -$refund = new Refund(); -$refund->setAmount($amt); - -$saleId = '3RM92092UW5126232'; - -// ###Sale -// A sale transaction. -// Create a Sale object with the -// given sale transaction id. -$sale = new Sale(); -$sale->setId($saleId); -try { - // Refund the sale - // (See bootstrap.php for more on `ApiContext`) - $sale->refund($refund, $apiContext); -} catch (PayPal\Exception\PPConnectionException $ex) { - echo "Exception:" . $ex->getMessage() . PHP_EOL; - var_dump($ex->getData()); - exit(1); -} -?> - - - Refund a sale - - -
Refunding sale id:
-
toJSON(JSON_PRETTY_PRINT);?>
- Back - - +details +// field to mention fees refund details. +$amt = new Amount(); +$amt->setCurrency('USD') + ->setTotal('0.01'); + +// ### Refund object +$refund = new Refund(); +$refund->setAmount($amt); + +$saleId = '3RM92092UW5126232'; + +// ###Sale +// A sale transaction. +// Create a Sale object with the +// given sale transaction id. +$sale = new Sale(); +$sale->setId($saleId); +try { + // Refund the sale + // (See bootstrap.php for more on `ApiContext`) + $sale->refund($refund, $apiContext); +} catch (PayPal\Exception\PPConnectionException $ex) { + echo "Exception:" . $ex->getMessage() . PHP_EOL; + var_dump($ex->getData()); + exit(1); +} +?> + + + Refund a sale + + +
Refunding sale id:
+
toJSON(128);?>
+ Back + + diff --git a/sample/vault/CreateCreditCard.php b/sample/vault/CreateCreditCard.php index bea54bd..6c1c358 100644 --- a/sample/vault/CreateCreditCard.php +++ b/sample/vault/CreateCreditCard.php @@ -42,7 +42,7 @@ try {
Saved a new credit card with id: getId();?>
-
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/sample/vault/GetCreditCard.php b/sample/vault/GetCreditCard.php index afdda0f..3d66c6c 100644 --- a/sample/vault/GetCreditCard.php +++ b/sample/vault/GetCreditCard.php @@ -29,7 +29,7 @@ try {
Retrieving saved credit card:
-
toJSON(JSON_PRETTY_PRINT);?>
+
toJSON(128);?>
Back diff --git a/tests/PayPal/Test/Common/ModelTest.php b/tests/PayPal/Test/Common/ModelTest.php index 7ca5f07..d8cc880 100644 --- a/tests/PayPal/Test/Common/ModelTest.php +++ b/tests/PayPal/Test/Common/ModelTest.php @@ -84,9 +84,6 @@ class ModelTest extends \PHPUnit_Framework_TestCase } } - /** - * @outputBuffering enabled - */ public function testInvalidMagicMethod() { $obj = new SimpleClass(); @@ -101,9 +98,6 @@ class ModelTest extends \PHPUnit_Framework_TestCase } } - /** - * @outputBuffering enabled - */ public function testInvalidMagicMethodWithDisabledValidation() { PPConfigManager::getInstance()->addConfigs(array('validation.level' => 'disabled'));