George, you asked for this …
Luckily on our current site that we have to keep it was easy to buy tickets because DMXZone made a great Dreamweaver extension that made it possible and easy.
Sorry, just had to get that dig in there
George, you asked for this …
Luckily on our current site that we have to keep it was easy to buy tickets because DMXZone made a great Dreamweaver extension that made it possible and easy.
Sorry, just had to get that dig in there
Oh well at least you gave it a shot.
The problem I see with extensions is that they need to be maintained. The Stripe API changes fairly regularly so the team would have to keep on top of it to maintain a decent plugin, that’s why the API connector is available.
I understand though it’s not easy for everyone but I would rather development hours go into the Wappler core product rather than plugins or extensions, but each to their own.
lol, I just can't seem to get this out of my head. I like my cart too much. I decided since I have told the board I can't do it I have some time now to get this working before we can resume putting on productions.
So, I am kinda trying to do sections at a time. Tried the API step without any databases. No idea if it will work, just had to start somewhere. Nothing to lose at this point.
When I click on my payment button I get the following error and the button does nothing.
What am I missing?
EDIT: Started trying it with the database inserts and updates.
It looks like you haven’t passed any line items to Stripe in your server api action. You can just send line_items[0][name] as ‘Tickets’ or ‘Basket Contents’ or similar.
Name | Value |
---|---|
success_url | https://mydomain.com/success |
cancel_url | https://mydomain.com/cancel |
mode | payment |
payment_method_types[0] | card |
customer_email | ***Note: Not required but pre-fills Stripe checkout |
line_items[0][currency] | usd |
line_items[0][amount] | {{totalPrice[0].TotalPrice * 100}} - Change for your query or price |
line_items[0][name] | Give this a description your user will recognise |
line_items[0][quantity] | 1 |
Hmmm, I have all of the ones you have there. Only difference is I have the amount hard coded as I haven’t go to the order total query yet.
Your amount needs to be as an integer rather than decimal
Changed it to 10 and made no difference.
For Square, this needs to be a minimum of $1 or 100. Maybe Stripe requires the same. (just trying to help)
Just a thought, I used the price_id update from Stripe. After you set up your products in stripe you will get a price id or each price you set for each product. So for example if you have different sizes of a product you could charge price1 for size1 and price2 for size2. Each of the prices has an associated price_id. If you paste the price_id in the value where you have 100.00 it works for me. The good thing is that with a price_id you don’t need a product id because each price is associated with an amount and product. So all you need is the price_id and quantity.
Thanks Daniel,
I’m not using the products in the Stripe dashboard. I’m using products from my own database. I have it all working perfectly now thanks to the help of this community.