Created
June 17, 2019 08:54
-
-
Save leewillis77/a4043e2b70e0ada39132d52daae00c82 to your computer and use it in GitHub Desktop.
Registers GTIN field from Product GTIN for WooCommerce plugin as a pre-population option.
This file contains 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
<?php | |
/** | |
* Registers a meta field as a prepopulation option. | |
*/ | |
function lw_woocommerce_gpf_custom_field_list( $list ) { | |
$list['meta:_wpm_gtin_code'] = 'GTIN field from Product GTIN for WooCommerce plugin'; | |
return $list; | |
} | |
add_filter( 'woocommerce_gpf_custom_field_list', 'lw_woocommerce_gpf_custom_field_list' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment