Jump to content
Larry Ullman's Book Forums

Chapter 15 Stripe

Recommended Posts

Hi Larry,

I am trying to use Stripe from my localhost and have established a test account with Stripe Australia.

I am getting error "Class 'Stripe\Stripe_Charge' not found in .....on line 182 -  I am on page 508 in the book.

I have Stack-Overflowed and tried their solutions but none work.

I am not able to use composer as I'm using PHP 5.5.3 on Windows 7 so I did the manual download and as far as I can tell all that is OK.

Again, any advice will be most appreciated.

Cheers, Necuima



Link to comment
Share on other sites

It's OK - I tried \Stripe\Charge:: etc and that did not give the error.

But now I have another error which seems to be associated with an SSL certificate.  As mentioned I am trying to test this on localhost which, in my case, does not have an SSL certificate.

I understood from a previous query on Stripe that I could test this from localhost without my XAMPP/Apache having an SSL certificate.  Have I mis-understood this?

The beginning of the error is:

"An error occurred in script 'C:\xampp\htdocs\DMChat\modules\process_payment.php' on line 213: Stripe\Error\ApiConnection Object ( [message:protected] => Unexpected error communicating with Stripe. If this problem persists, let us know at support@stripe.com. (Network error [errno 77]: error setting certificate verify ..............."

This was from the catch block:

catch (Exception $e)
     { // Try block failed somewhere else.
      trigger_error(print_r($e, 1));

Again, your advice will be most appreciated,


P.S., you can probably figure out that I am using your model/view/controller approach from the advanced book :-)

Link to comment
Share on other sites


  • Create New...