When using the square-php-sdk all I get is that error message.
Uncaught Error: Call to undefined method Unirest\Request::enableRetries() in /home/xxx/xxx/xxx/square-web-payments/src/Apis/BaseApi.php:64
autoload.php contains:
"Square\\" => "/src/",
"apimatic\\jsonmapper\\" => "/jsonmapper/src/",
// This is the Namespace and location from Apimatic/Unirest's composer.json
"Unirest\\" => "/unirest-php/src/Unirest/",
];
The paths are correct. If I change the Unirest path I get an error it can’t be found so it is loading correctly.
Did I not give you enough information with my reply?
Seems like you guys would be on this since you are removing sqPayemtForm in less than a week. I have a couple of hundred Square users that are going to be pissed the 21st.
Have you confirmed that you’re getting the token prior to passing it to the payment request? That error is saying that it’s null. Is it even being generated?
No clue if I’m getting the token. Haven’t done or need to do anything in php in over 8 years. Trying to figure this out quickly. How can I tell if I’m getting the token? Is there paid support somewhere? I need the form → Process payment .
When I change the form payment-process.php to /payment I get
JSON.parse: unexpected character at line 1 column 1 of the JSON data [square.js:1:94027](https://sandbox.web.squarecdn.com/v1/square.js)
Ve https://sandbox.web.squarecdn.com/v1/square.js:1
handlePaymentMethodSubmission https://www.bigdippergraphics.com/public/examples/card.php:120
<anonymous> https://www.bigdippergraphics.com/public/examples/card.php:126
n https://sandbox.web.squarecdn.com/v1/square.js:1
(Async: EventListener.handleEvent)
It https://sandbox.web.squarecdn.com/v1/square.js:1
Ve https://sandbox.web.squarecdn.com/v1/square.js:1
<anonymous> https://www.bigdippergraphics.com/public/examples/card.php:125
<anonymous> https://www.bigdippergraphics.com/public/examples/card.php:80