• Resolved braunsch

    (@braunsch)


    Hello!

    As a sports club website, I need my members to acknowledge/sign a waiver during the checkout process. Ideally, I would like to have this as a separate step in the checkout.

    I would like this step to be shown only if

    • a club member is logged in, and
    • a product of a specific type is in my cart (I don’t need the waiver for donations, but I do need it when someone buys a new membership).

    If this is possible (I know I’d have to write a bit of code to make this happen), the next question comes up:

    • Is there a way to place “free text” (i.e., my waiver text) on a checkout step and require acknowledgement?
    • Is it possible to call a form from within the checkout to collect the signature, e.g., via shortcode? (this would allow me to collect the waiver signatures).

    Thank you for your assistance!

    Georg

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Diana Burduja

    (@diana_burduja)

    Hello Georg,

    you can programmatically add a custom step to the plugin. The Customizations section of the documentation for the plugin’s pro version is valid also for the free version. There you’ll find an example for adding a custom step.

    It’s not possible to “call a form” or to “collect the signature via a shortcode” inside the custom step. The reason for that is: the checkout form by itself is already a <form> element; adding another <form> element inside the checkout <form> is strictly forbidden (see this MDN article). Instead you can use the “woocommerce_checkout_fields” filter in order to add custom input fields to the checkout form, i.e. within your newly added custom step (see this article on how to add input fields to the checkout form).

    If you need to build a custom step with a simple waiver, then you might consider using the Minimum Age for WooCommerce plugin. After installing this plugin you’ll also find an option called “Show the Minimum Age fields in a separate step” on the “WP Admin -> WooCommerce -> Multi-Step Checkout” page. It’s possible to also build on top of this solution in order to remove the “Minimum Age” step when a certain product is in the cart (see the “Delete a step based on products in the cart” section of the documentation, valid also for the plugin’s free version). Additionally, you can use the “wpmc_modify_steps” filter in order to remove the “Minimum Age” step when a club member is logged in (see the “Removing a step” section in the documentation).

Viewing 1 replies (of 1 total)
  • The topic ‘Additional (conditional) checkout step?’ is closed to new replies.