• Resolved tw2021

    (@tw2021)


    Hi Support,

    i have 3 questions each with a checkbox on the checkout page

    When user checked, the question will showed XXX – yes and displayed as part of their order, however, when user leave the checkbox blank, this is not recorded anywhere.

    Is it possible to make the questions to still display on the orders page etc when the checkbox is unchecked?

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Tomasz WP Desk

    (@tomaszwp)

    Hello @tw2021

    The unchecked checkbox does not have the opposite value to the checked one. It is not possible to get this value.

    There is a possible workaround.
    Please uncheck the Display field label checkbox in the Display On tab.
    Then go the General tab and add a Value that will determine whether the checkbox is selected or not e.g. I want an invoice. This Value is clear even without a label.

    With the field set as above:

    • when the user selects the checkbox then I want an invoice will appear (in the mail etc.)
    • if the customer does not check the checkbox then nothing will appear (because the label is hidden and the value is missing)

    Of course this is the solution when the goal is to mark (e.g. in the mail) whether the customer ticked the checkbox or not. But that will not solve the problem of the unchecked checkbox not having a value.

    Thread Starter tw2021

    (@tw2021)

    Hi Tomasz,

    Thank you for the super fast response. Ah, yea the workaround won’t work because my checkout contains 3 questions which is a survey (can contain yes and no) that i would like to send to the orders page 🙁

    Do you know if its even possible to modify the woocommerce default value of blank checked box to a value “No” by default?

    Thank you.

    Plugin Support Tomasz WP Desk

    (@tomaszwp)

    Hello @tw2021

    I do not know how to edit default checkboxes from WooCommerce because it is a different plugin.
    If the question concerned our plugin – then the field template can be overwritten.
    This the location of the file responsible for the checkbox:
    wp-content/plugins/flexible-checkout-fields/templates/fields/inspirecheckbox.php
    This template can be overridden by copying it to:
    theme-name/flexible-checkout-fields/fields/inspirecheckbox.php

    Plugin Support Tomasz WP Desk

    (@tomaszwp)

    I am marking this topic as resolved as we have not received any new replies.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘When checkbox is unchecked’ is closed to new replies.