Created
June 3, 2015 03:37
-
-
Save WillBrubaker/4d9f1cd122513e9eb0bc to your computer and use it in GitHub Desktop.
Restrict WooCommerce order notes field to a number of characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'woocommerce_checkout_fields', 'filter_checkout_fields' ); | |
function filter_checkout_fields( $fields ) { | |
$fields['order']['order_comments']['maxlength'] = 200; | |
return $fields; | |
} |
Author
WillBrubaker
commented
Feb 20, 2020
becuase i have a pugin that modifies the checkout as well, my modifications did not display, but when i deactivated the plugin it worked ! :D
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment