billplz-wrapper's People
Forkers
pbaldikabillplz-wrapper's Issues
Issue on createBill() function
I am currently using your billplz-wrapper package and I am facing an issue when creating a bill. Below is the create bill function I implemented on my project:
public function createBill(Request $request)
{
//dd($request);
$res0 = new BillplzBill;
// $res0->collection_id = $request->collection; // which collection you want to park this bill under
$res0->collection_id = $request->collection; // which collection you want to park this bill under
$res0->description = $request->desc; // bill description
$res0->email = $request->email; // client email
$res0->name = $request->name; // cleint name
$res0->amount = $request->totPrice * 100; // by default in cent
$res0->callback_url = "http://127.0.0.1:8000/"; // callback url after execution
// and other optional params
$res0 = $res0->create_bill();
list($rhead ,$rbody, $rurl) = explode("\n\r\n", $res0);
$bplz_result = json_decode($rurl);
return redirect($bplz_result->url);
}
Using the Create bill function, I am able to successfully create a bill on my BillPlz account, But after the in the function call of create_bill(), the next line of code from your package tutorial template (shown below) does not work for me.
list($rhead ,$rbody, $rurl) = explode("\n\r\n", $res0);
$bplz_result = json_decode($rurl);
It resulted on an undefined array key 2 error.
I am enquiring you here to ask for assistance to resolve this issue, I hope you are able to assist me in this matter as I am currently have been attempting to resolve it for the past week and still have not found a solution.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.