#wagamumma_code
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1344624389379063873
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
hi there!
how are you accepting payments? Checkout Session, Payment Element, something else?
"Accept a payment"
but how do you accept payments?
I'm not sure there are so many different names for everything its confusing ๐ all I know is the last person I spoke to sent us this link
const paymentElement = elements.create('payment', paymentElementOptions);
this is the Payment Element ๐
can you share a link where you don't see Apple Pay?
not very easily as you'd need to add something to cart and enter name/address etc i think?
We sell a huge range of fabrics and wallpapers. We offer a bespoke curtain & blind making service from a choice of thousands of fabrics, many of which we keep in stock. Also we have a cookshop and linen department.
that would be the final checkout page though
ive registered the domain, and with apple, and added the apple file to .well-known etc
let me try
thanks, if you do need to add something to cart you'd need to then go to the link below to get to this checkout (as it's separate to the live website)
can you give me a email/password of a test account?
got it. and Apple Pay should show up when exactly? after I click on Pay Now?
that's odd, that should be showing the whole payment form
oh so the Payment Element should render on that page?
looks like there's an error on your end:
could you refresh that page, that was when I was testing earlier though I'm not sure why it's erroring for you now
same error. the URL I'm on: https://www.gordonsmithmalvern.co.uk/checkout_payment/
i dont understand that i removed the changes and re-uploaded create.php... its working for me still, could yoiu test as a guest instead maybe if you log out first? https://www.gordonsmithmalvern.co.uk/logout/
We sell a huge range of fabrics and wallpapers. We offer a bespoke curtain & blind making service from a choice of thousands of fabrics, many of which we keep in stock. Also we have a cookshop and linen department.
should it be complicated to get apple pay to work? i followed the guide and did everything
(to be a guest by the way you just need to enter any name/address not use the sign in as customer bit
where is the option for "guest customer"?
now it works, and I do see Apple Pay
are you using a compatble device/browser, and do you have a card saved in your Apple Wallet?
oh how strange, is there any way to test this on a non IOS device too? it wasn't working on our clients iphone, also is there any way to re-order the payment methods to put apple pay at the top?
oh how strange, is there any way to test this on a non IOS device too?
what do you mean? Apple PAy is not avaoible on Android phones
no i mean for testing this as I dont have an IOS device myself to test with
also is there any way to re-order the payment methods to put apple pay at the top?
yes: https://docs.stripe.com/js/elements_object/create_payment_element#payment_element_create-options-paymentMethodOrder
sandbox/simulated somehow
no sorry, you need iOS or a mac, and have a card saved into your wallet.
ok thanks, lastly, it mentions this:
Request Apple Pay merchant token
If youโve configured your integration to accept Apple Pay payments, we recommend configuring the Apple Pay interface to return a merchant token to enable merchant initiated transactions (MIT). Request the relevant merchant token type in the Payment Element.
is this necessary as I don't fully understand what it's saying to do here?
this is only if you plan to save the card details to charge the customer later, while they are not on your website.
ah ok i see, sorry 1 more question it mentioned putting this into the code (this is the bit that "breaks" the whole page from loading when I add it though for some reason)
$stripe->paymentMethodDomains->create(
['domain_name' => 'example.com'],
['stripe_account' => '{{CONNECTED_ACCOUNT_ID}}']
);
sorry lol.. but yeah that bit is it required?
are you using Stripe Connect?
I guess not, sorry it's all a bit new to me and not sure what all the different terms are
Stripe Connect is when you do multi-party payments, like giving 20% of your sales to someone else
if you think it's all working correctly I guess that's good enough for me! theres no more steps I'd need to do it should juist work for someone on IOS witha card added?
ah i see no
if not, then why use ['stripe_account' => '{{CONNECTED_ACCOUNT_ID}}']?
also $stripe->paymentMethodDomains->create should only be called once to configure the domain. not every time someone tries to pay.
it just said to do that as part of adding apple pay, i just followed the help doc
it just said to do that as part of adding apple pay, i just followed the help doc
can you share the link where you saw this?
ok hopefuly just adding the domains on the stripe dashboard is enough
yes it is
yeh it says this is for connect so that's my bad! i didn't know the terms just followed the whole page
hopefully everything is fine then, thank you for your help!
happy to help ๐
on the re-ordering, is there any examples on how this would look as I don't see an example or know what the exact names would be for each method? do you have an example of this being used anywhere?
or can it be done in dashboard?
it can't be done in the dashboard, no
just want apple pay top then card basically then anything else
I haven't tested it, but it should be something like paymentMethodOrder: ["apple_pay", "card"]
so it should be in checkout.js like this ?
const paymentElementOptions = {
layout: "accordion",
paymentMethodOrder: ["apple_pay", "card"]
};
const paymentElement = elements.create("payment", paymentElementOptions);
yes
We sell a huge range of fabrics and wallpapers. We offer a bespoke curtain & blind making service from a choice of thousands of fabrics, many of which we keep in stock. Also we have a cookshop and linen department.
is it possible you could refresh for me and see if that worked (sorry!)
it's like before:
oh guess that doesn't work then ๐ฆ
ive found an exmaple its using single quotes, could you refresh again and see if it works now please?
elements.create('payment', {
paymentMethodOrder: ['apple_pay', 'google_pay', 'card', 'klarna']
});
what I recommend:
- add a card to pay.google.com (for Google Pay to work)
- then use
paymentMethodOrder: ["google_pay", "card"], - this way you can check directly on your end if it's working on it
ive found an exmaple its using single quotes, could you refresh again and see if it works now please?
using single quote or double quote should have zero impact
i just wondered if it needs to be refreshed a few times for it to update for you like on PC its ctrl+f5 not sure what that would be on mac/ios
i can certainly try setting up google pay to test that first but our client is desperate to get apple pay working and wants it to be the 1st option
still not working on my end. but first try to get Google Pay working, and then you can just change your code for apple pay
ok i will try that now, thanks for you help
and if you need help with this, please let us know