| Server IP : 162.214.74.102 / Your IP : 216.73.217.114 Web Server : Apache System : Linux dedi-4363141.lrsys.com.br 3.10.0-1160.119.1.el7.tuxcare.els25.x86_64 #1 SMP Wed Oct 1 17:37:27 UTC 2025 x86_64 User : lrsys ( 1015) PHP Version : 5.6.40 Disable Function : exec,passthru,shell_exec,system MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/lrsys/public_html/lrsys_apps/team/application/libraries/stripe-php/lib/ |
Upload File : |
<?php
namespace Stripe;
class Card extends ApiResource
{
/**
* @return string The instance URL for this resource. It needs to be special
* cased because it doesn't fit into the standard resource pattern.
*/
public function instanceUrl()
{
$id = $this['id'];
if (!$id) {
$class = get_class($this);
$msg = "Could not determine which URL to request: $class instance "
. "has invalid ID: $id";
throw new Error\InvalidRequest($msg, null);
}
if (isset($this['customer'])) {
$parent = $this['customer'];
$base = Customer::classUrl();
} elseif (isset($this['recipient'])) {
$parent = $this['recipient'];
$base = Recipient::classUrl();
} else {
return null;
}
$parent = ApiRequestor::utf8($parent);
$id = ApiRequestor::utf8($id);
$parentExtn = urlencode($parent);
$extn = urlencode($id);
return "$base/$parentExtn/cards/$extn";
}
/**
* @param array|null $params
* @param array|string|null $opts
*
* @return Card The deleted card.
*/
public function delete($params = null, $opts = null)
{
return $this->_delete($params, $opts);
}
/**
* @param array|string|null $opts
*
* @return Card The saved card.
*/
public function save($opts = null)
{
return $this->_save($opts);
}
}