Mailchimp Banner | Q2 2024

added by Latoya

Product Icon

Product Add-Ons

by  Woo
Offer add-ons like gift wrapping, special messages or other special options for your products.

Text Fields: Stop the user from exceeding the maximum number of characters (as previous)

The handling of text fields has been changed, negatively impacting usability.

PRIOR TO VERSION 6.0.0: The website developer would create a text field and configure a minimum and maximum number of characters for that field. When a user started entering text, the plugin displayed the message: “xx characters remaining”. Critically, it stopped the user from exceeding the maximum limit.

WooCommerce’s documentation for this plugin shows the text field working as just described:

Product Add-Ons

This is the way most ‘Contact Us’ forms work, so users are familiar with it.

VERSION 6.0.0 AND AFTER: The website developer creates a text field and configures a minimum and maximum number of characters for that field. When a user starts entering text, the plugin doesn’t inform the user of the limit or how many characters remain until the limit is reached. The user can keep typing, exceed the limit, and only then an error message is displayed: “Please enter up to xx characters”. The user then has to understand that they need to delete characters until they are within limit. This is non-standard and not intuitive, which will result in some customers abandoning their order.

Please return the functionality to how it worked previously.

Author

marlakittycollars

Current Status

Closed

Last updated: October 23, 2023

2 comments

Log in to comment on this feature request.

  1. marlakittycollars says:

    The new functionality is very poor for user experience.

  2. jaskyt8 says:
    Product Developer May 24, 2024 8:22 am

    Hey there,

    Thank you for getting in touch!

    You are right that after the recent Product Add-On updates, we changed how we validate user input inside the add-ons form. Specifically for Short Text and Long Text add-ons with a Maximum Character Limit, customers can now type as many characters as they like. When/If they exceed the Maximum Character Limit, an error will show up and it won’t be possible to add the product to the cart.

    From a technical perspective, the only way to prevent customers from typing more characters is by defining a ‘maxlength’ attribute on the input element. By doing so, though, the browser takes over the input’s validation and it is not possible for Product Add-Ons, or any other piece of code, to display tailored error messages to users.

    From a user experience perspective, it is generally considered better practice to allow users to type as many characters as they like and display an error message only when they exceed the character limit, rather than abruptly preventing them from typing more characters without any explanation.

    I definitely understand that the new validation behavior might not be a good fit for your store, especially since add-ons validation used to be very different for many years in the past. However, since we believe that the new validation system is better for the majority of the users and we haven’t received many requests suggesting otherwise, we do not plan to roll back to the old way of validating add-ons.

    As an alternative for your store, I encourage you exploring the option of writing custom code to prevent users from writing more characters in the Short/Long Text add-ons than those allowed. To help you with this, I suggest getting in touch with a Woo Expert: https://partners.woocommerce.com/English/marketplace/ or an experience WooCommerce developer from Codeable: https://www.codeable.io/.