I have integrated Stripe payment gateway in my client’s woo commerce website.
But when I tested in Live mode, input fields are not allowing to add the card details. When I checked it displays:
<!– a Stripe Element will be inserted here. –>”
I have integrated Stripe payment gateway in my client’s woo commerce website.
But when I tested in Live mode, input fields are not allowing to add the card details. When I checked it displays:
<!– a Stripe Element will be inserted here. –>”
2
Answers
Odds are pretty good the browser console shows some Javascript errors that are causing the Stripe Elements to not render properly, so I’d suggest having a look at your browser console.
Check the details of the browser console, if there are any errors fix them first
Also make sure that you are on the checkout page, i.e. the
is_checkout()
function returns true. If you have custom checkout page you can usewoocommerce_is_checkout
filter to return true according to your code, and then Stripe fields will be initialized correctly.