woocommerce_csv_product_import_valid_filetypes
Get all the valid filetypes for a CSV file.
Usage
add_filter( 'woocommerce_csv_product_import_valid_filetypes', 'wp_kama_woocommerce_csv_product_import_valid_filetypes_filter' ); /** * Function for `woocommerce_csv_product_import_valid_filetypes` filter-hook. * * @param $array * * @return */ function wp_kama_woocommerce_csv_product_import_valid_filetypes_filter( $array ){ // filter... return $array; }
- $array
- -
Where the hook is called
woocommerce_csv_product_import_valid_filetypes
woocommerce/includes/admin/importers/class-wc-product-csv-importer-controller.php 160-166
return apply_filters( 'woocommerce_csv_product_import_valid_filetypes', array( 'csv' => 'text/csv', 'txt' => 'text/plain', ) );