Redirect after recaptcha submit wont fire form.posted_successfully

Hi all,

Since mailchimp is no longer supported I use Shopify’s native opt-in signup form to let users subscribe for newsletters, this works like a charm .. so far no problems.

When the form is posted successfully a confirmation text is shown. This works when the form could be posted directly, however when the user get’s challenged by recaptcha and click’s the submit button he/she get’s redirected without the “customer_posted=true” parameter in the url and therefore the {% if form.posted_successfully? %} won’t work anymore.

Code looks like this … like most examples

{% form 'customer' %}
  {% if form.posted_successfully? %}
    {{section.settings.subscription_confirmation}}
  {% else %}
     ...input fields
  {% endif %}
{% endform %}

Does anybody experienced a problem like this and knows how to solve this?

1 Like

Sadly, experiencing the same and haven’t found a way around it.

It’s very intermittent, with desktop redirecting fine., but not a mobile device (iOS, Chrome)

1 Like

{% form ‘customer’ %}
{% if form.posted_successfully? %}
{% elsif form.errors %}
{% for field in form.errors %}

{{ field }} - {{ form.errors.messages[field] }}

{% endfor %} {% endif %}

QUESTION: After client submit newsletter - I want them to redirect to specific page, let say www.xyz.com/thank-you

What should I add to the code above?