Reputation: 55
when PayPal form request in controller error occurs this
Object of class Illuminate\Routing\Redirector could not be converted to string
Error in Controller I think this function create error setExpressCheckout()
$provider = new ExpressCheckout;
$response = $provider->setExpressCheckout($data);
$response = $provider->setExpressCheckout($data, true);
return redirect($response['paypal_link']);
Thanks in advance
Upvotes: 1
Views: 67
Reputation: 9029
You may redirect to a domain outside of your application by calling the away
method:
return redirect()->away($response['paypal_link']);
See Laravel docs for more info.
Upvotes: 1