Skip to content

Instantly share code, notes, and snippets.

Last active August 23, 2017 17:04
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
WooCommerce : Disable Autofocus on the First Name field under Billing and Shipping address.
/* Disable autofocus on the billing First Name field */
function disable_autofocus_billing_firstname($fields) {
$fields['billing_first_name']['autofocus'] = false;
return $fields;
/* Disable autofocus on the shipping First Name field */
function disable_autofocus_shipping_firstname($fields) {
$fields['shipping_first_name']['autofocus'] = false;
return $fields;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment