Stripe is not displayed on the publish version

Hi, I managed to set up the stripe plugin by following this documentation plugins/extensions/stripe.
And it works with the test API key in the editor.

But when I publish the project, the Stripe payment form does not appear. ( I don’t have domains yet ).
Here is my link https://67fe9c53-a913-4d20-a7d2-44611bc7a373.weweb-preview.io/test/

Why is it written “display: none;” on the div ? Do you have any ideas ? Thanks

1 Like

Hello @elna,

On page load, you have a workflow to create the payment_intent_client_secret and set it in the stripe element. All the actions on this workflow are disabled. Could you try to activate them, republish and see if it’s working?

Hello @Mael, thank you for the response :slight_smile:

I had disabled this workflow on the page, to try it directly on the application (settings/general/workflows) (and not on the page), but that didn’t work either.
As you told me, I just reactivated the workflow and all the actions it contains. And republish, but Stripe still doesn’t appear.

I finally found the issue

The stripe element is not display because your element is load but the payment_intent_client_secret doesn’t exist yet

On your form, you need to bind the parameter conditional rendering to the formula: payment_intent_client_secret != ""

With this formula, the stripe element will be created only when the payment_intent_client_secret exist

2 Likes

Congratulations :partying_face:, I never would have thought of this issue.
Maybe you should add it in your Stripe documentation.

Now it works perfectly.
Thank you very much :pray:

1 Like

Done :slight_smile: Thanks for highlighting this for us!

1 Like