woocommerce_downloadable_product_name filter-hook . WC 1.0
Download name will be 'Product Name' for products with a single downloadable file, and 'Product Name - File X' for products with multiple files.
Usage
add_filter( 'woocommerce_downloadable_product_name', 'filter_function_name_1796', 10, 4 ); function filter_function_name_1796( $download_file_name, $product, $download_id, $file_number ){ // filter... return $download_file_name; }
- $download_file_name
- -
- $product
- -
- $download_id
- -
- $file_number
- -
Where the hook is called
woocommerce_downloadable_product_name
woocommerce/includes/wc-user-functions.php 618-624
$download_name = apply_filters( 'woocommerce_downloadable_product_name', $download_file['name'], $_product, $result->download_id, $file_number );