Jonjie Jonjie - 10 months ago 49
PHP Question

PayPal donation integration with laravel 5.1

I've searched over the internet about this problem but still stack with it. I'm trying to create a

donation page
, where they can enter the amount they want, then after that they will be redirected into the
page/website, and works fine. But how can I test it if it is working or not. I've created
sandbox paypal account which I think it is for testing but whenever I try to pay/login my account using the
sandbox account
, I can't use it. It seems that the credentials I'm trying to use in login doesn't exists. Why is that? Please see my code below for code reference. What should I do with this?


<form method="POST" action="" role="form">
<div class="form-group">
<input type="hidden" name="cmd" value="_donations">
<input type="hidden" name="business" value="KOWG3LKOLPR32">
<input type="hidden" name="amount" value="{{ $value }}" class="pure-number">
<div class="form-group">
<input type="submit" class="btn btn-info" value="Proceed to PayPal">


I've changed this
<form method="POST" action="" role="form">
to this
<form method="POST" action="" role="form">
but after the transaction is done, it won't redirect to my page, I think it should be.

Answer Source

you should add a return back and cancel field.

<input type="hidden" name="return" value="">
<input type="hidden" name="cancel_return" value="">
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download