Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 95243d0

Browse filesBrowse files
Fix indentation
1 parent 67e11da commit 95243d0
Copy full SHA for 95243d0

File tree

1 file changed

+11
-9
lines changed
Filter options

1 file changed

+11
-9
lines changed

‎src/Paystack.php

Copy file name to clipboardExpand all lines: src/Paystack.php
+11-9Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -124,25 +124,27 @@ public function makePaymentRequest( $data = null)
124124
"last_name" => request()->last_name,
125125
"callback_url" => request()->callback_url,
126126
"currency" => (request()->currency != "" ? request()->currency : "NGN"),
127+
127128
/*
128129
Paystack allows for transactions to be split into a subaccount -
129130
The following lines trap the subaccount ID - as well as the ammount to charge the subaccount (if overriden in the form)
130131
both values need to be entered within hidden input fields
131132
*/
132133
"subaccount" => request()->subaccount,
133134
"transaction_charge" => request()->transaction_charge,
135+
134136
/*
135137
* to allow use of metadata on Paystack dashboard and a means to return additional data back to redirect url
136138
* form need an input field: <input type="hidden" name="metadata" value="{{ json_encode($array) }}" >
137-
*array must be set up as: $array = [ 'custom_fields' => [
138-
* ['display_name' => "Cart Id", "variable_name" => "cart_id", "value" => "2"],
139-
* ['display_name' => "Sex", "variable_name" => "sex", "value" => "female"],
140-
* .
141-
* .
142-
* .
143-
* ]
144-
*
145-
* ]
139+
* array must be set up as:
140+
* $array = [ 'custom_fields' => [
141+
* ['display_name' => "Cart Id", "variable_name" => "cart_id", "value" => "2"],
142+
* ['display_name' => "Sex", "variable_name" => "sex", "value" => "female"],
143+
* .
144+
* .
145+
* .
146+
* ]
147+
* ]
146148
*/
147149
'metadata' => request()->metadata
148150
]);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.