Skip to content

[5.x]: Disable automatic button rendering #1073

Discussion options

You must be logged in to vote

Hi @mikesnoeren,

You are correct that this has changed in Freeform 5, but there is a way to disable the automatic button rendering and set it yourself. 🙂

You can see the options available in the documentation, but you might likely wish to go this route:

{{ form.renderTag({
    returnUrl: "contact/success",
    disable: ["submitButtons"]
}) }}

    {# Your fields #}

    {% set page = form.pages.current %}

    <button {{ page.buttons.submitRenderProps({ 'data-optional': 'attributes here' }) }}>
        Submit
    </button>
    {% if form.pages.current.buttons.back %}
        <button {{ page.buttons.backRenderProps }}>
            Back
        </button>
    {% endif %}
    {% if form.pages.c…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by kjmartens
Comment options

You must be logged in to vote
1 reply
@kjmartens
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #1070 on February 20, 2024 21:19.