Added invoice samples

This commit is contained in:
siddick
2014-04-23 17:43:04 +05:30
parent bca7fe7268
commit bb21c1e445
6 changed files with 240 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
<?php
require __DIR__ . '/../bootstrap.php';
use PayPal\Api\Invoice;
try {
$invoice = Invoice::get("INV2-9DRB-YTHU-2V9Q-7Q24", $apiContext);
$sendStatus = $invoice->send($apiContext);
} catch (PayPal\Exception\PPConnectionException $ex) {
echo "Exception: " . $ex->getMessage() . PHP_EOL;
var_dump($ex->getData());
exit(1);
}
?>
<html>
<head>
<title>Send Invoice</title>
</head>
<body>
<div>Send Invoice:</div>
<pre><?php var_dump($invoice);?></pre>
<a href='../index.html'>Back</a>
</body>
</html>