Basics of Integrating Stripe with PHP | Accept Credit Card Payments on Your PHP Site

Поділитися
Вставка
  • Опубліковано 18 лис 2024

КОМЕНТАРІ • 10

  • @stront
    @stront Рік тому +1

    Just what I've been looking for. First tutorial that actually works for me. Only thing I can't seem to get to work is retrieving the customers information so I can display it or import it into my database. Any chance you've got code for that that works with the demo code you provided? Or maybe a tutorial? Cheers.

    • @johnnycode
      @johnnycode  Рік тому

      I don't save customer info so I don't have code for that. Before you can retrieve a customer, you have to first create the customer in Stripe. It sounds like you didn't create the customers in Stripe first?

  • @KalmanWebDesign
    @KalmanWebDesign 11 місяців тому

    So how would you change the quantities when a customer changes them on the product?

    • @johnnycode
      @johnnycode  11 місяців тому +1

      From your front end UI, when the customer changes the item quantity and clicks a submit button, then your backend PHP code would know the quantity required. Alternatively, you could use something like jquery.post() to send the quantity to the backend PHP when the customer triggers a onChange() event on the quantity input box.

    • @KalmanWebDesign
      @KalmanWebDesign 11 місяців тому +1

      Thanks!@@johnnycode

  • @Hamster2wire
    @Hamster2wire 3 місяці тому

    Hi, may I know how to get lineItems data from cart page?

    • @johnnycode
      @johnnycode  3 місяці тому

      lineItems data is an array that you construct and store in the user's session when your customer adds an item to cart. This is something you do in PHP and is not relevant to Stripe; you just have to create the array in the format shown in the video. Look into how to do a basic PHP shopping cart.

  • @rust_soldier
    @rust_soldier Рік тому

    Fatal error: Uncaught (Status 400) (Request req_dRL7O7hJBqtmJF) Invalid array thrown in

  • @tianadede349
    @tianadede349 Рік тому

    thanks bro

  • @kannyiriabdulai8776
    @kannyiriabdulai8776 Рік тому

    👍