Skip to content
Browse files

More readable concatenation in examples

  • Loading branch information...
1 parent 7824c7e commit 0bd40431eed5b3180e9fb068fedbd9d6e065156f @DHS DHS committed Apr 22, 2012
Showing with 10 additions and 10 deletions.
  1. +7 −7 examples/merchant.php
  2. +3 −3 examples/partner.php
View
14 examples/merchant.php
@@ -73,7 +73,7 @@
);
$bill_url = GoCardless::new_bill_url($payment_details);
-echo '<p><a href="'.$bill_url.'">New bill</a>';
+echo '<p><a href="' . $bill_url . '">New bill</a>';
// New subscription
@@ -84,7 +84,7 @@
);
$subscription_url = GoCardless::new_subscription_url($payment_details);
-echo ' &middot; <a href="'.$subscription_url.'">New subscription</a>';
+echo ' &middot; <a href="' . $subscription_url . '">New subscription</a>';
// New pre-authorization
@@ -100,20 +100,20 @@
);
$pre_auth_url = GoCardless::new_pre_authorization_url($payment_details);
-echo ' &middot; <a href="'.$pre_auth_url.'">New pre-authorized payment</a></p>';
+echo ' &middot; <a href="' . $pre_auth_url . '">New pre-authorized payment</a></p>';
echo '<p>NB. The \'new pre-authorization\' link is also a demo of pre-populated
user data.</p>';
echo '<h2>API calls</h2>';
-echo 'GoCardless_Merchant::find(\''.$account_details['merchant_id'].'\')';
+echo 'GoCardless_Merchant::find(\'' . $account_details['merchant_id'] . '\')';
echo '<blockquote><pre>';
$merchant = GoCardless_Merchant::find($account_details['merchant_id']);
print_r($merchant);
echo '</pre></blockquote>';
-echo 'GoCardless_Merchant::find(\''.$account_details['merchant_id'].'\')->pre_authorizations()';
+echo 'GoCardless_Merchant::find(\'' . $account_details['merchant_id'] . '\')->pre_authorizations()';
echo '<blockquote><pre>';
$preauths = GoCardless_Merchant::find($account_details['merchant_id'])->pre_authorizations();
print_r($preauths);
@@ -137,13 +137,13 @@
// code. NB. This is an example of filtering API results. More info here:
// https://gocardless.com/docs/api_guide#filtering
-//echo 'GoCardless_Merchant::find(\''.$account_details['merchant_id'].'\')->pre_authorizations(array(\'source_id\' => \'123\'))';
+//echo 'GoCardless_Merchant::find(\'' . $account_details['merchant_id'] . '\')->pre_authorizations(array(\'source_id\' => \'123\'))';
//echo '<blockquote><pre>';
//$preauths = GoCardless_Merchant::find($account_details['merchant_id'])->pre_authorizations(array('source_id' => '123'));
//print_r($preauths);
//echo '</pre></blockquote>';
-echo 'GoCardless_Merchant::find(\''.$account_details['merchant_id'].'\')->subscriptions()';
+echo 'GoCardless_Merchant::find(\'' . $account_details['merchant_id'] . '\')->subscriptions()';
echo '<blockquote><pre>';
$subscriptions = GoCardless_Merchant::find($account_details['merchant_id'])->subscriptions();
print_r($subscriptions);
View
6 examples/partner.php
@@ -83,8 +83,8 @@
<br />Copy and paste this access token into the top of the code for this
page to continue testing the partner demo. In your own app, you\'ll want to
save it to your database.
- <br />Access token: '.$account_details['access_token'].'
- <br />Merchant id: '.$account_details['merchant_id'].'</p>';
+ <br />Access token: ' . $account_details['access_token'] . '
+ <br />Merchant id: ' . $account_details['merchant_id'] . '</p>';
}
@@ -156,6 +156,6 @@
'redirect_uri' => 'http://localhost/examples/partner.php'
);
$authorize_url = $gocardless_client->authorize_url($authorize_url_options);
- echo '<p><a href="'.$authorize_url.'">Authorize app</a></p>';
+ echo '<p><a href="' . $authorize_url . '">Authorize app</a></p>';
}

0 comments on commit 0bd4043

Please sign in to comment.
Something went wrong with that request. Please try again.