Self made website - Checkout help

Can I pay you $25 to send me the files where I just need to change the credentials ?
This is so confusing and I feel like you’re going to give up on me any second :confused:

This is the file that works but gives me auth error (but it does not createpayment function etc) (it also does not create any error file in my webserver):
https://filebin.net/smey29gjn7r973pi/process-card.php?t=0e25bf8a

Here is the file that has more functions, but stops and gives error:
https://filebin.net/hgovwmpfpy9cqn7i/process-card.php?t=j4m48br1
The error is:
“PHP Fatal error: Uncaught Error: Class ‘Square\SquareClient’ not found”

But I actually do have “use Square\SquareClient;” in the php file

Which do you recommend I use?

For the first one: you have an invalid access token, that’s the only way unauthorized errors happen.
For the second one: I think I know what’s happening. It sounds like you downloaded the old SDK, but not the new SDK. The old SDK and new SDK have different models (for example Configuration vs SquareClient), so the autoload is probably working, but since you have the wrong SDK it still doesn’t actually exist. This is the current (new) SDK: GitHub - square/square-php-sdk: PHP client library for the Square API.

1 Like

Thank you for being absolutely amazing. I truly, do appreciate your help and can’t emphasize how patient you have been!! :slight_smile:

1 Like