parent
b240de4204
commit
f1c6b3628a
|
@ -1177,7 +1177,7 @@ class WC_Meta_Box_Product_Data {
|
|||
|
||||
// Validate the file extension
|
||||
if ( in_array( $file_is, array( 'absolute', 'relative' ) ) ) {
|
||||
$file_type = wp_check_filetype( strtok( $file_url, '?' ) );
|
||||
$file_type = wp_check_filetype( strtok( $file_url, '?' ), $allowed_file_types );
|
||||
$parsed_url = parse_url( $file_url, PHP_URL_PATH );
|
||||
$extension = pathinfo( $parsed_url, PATHINFO_EXTENSION );
|
||||
|
||||
|
@ -1465,7 +1465,7 @@ class WC_Meta_Box_Product_Data {
|
|||
|
||||
// Validate the file extension
|
||||
if ( in_array( $file_is, array( 'absolute', 'relative' ) ) ) {
|
||||
$file_type = wp_check_filetype( strtok( $file_url, '?' ) );
|
||||
$file_type = wp_check_filetype( strtok( $file_url, '?' ), $allowed_file_types );
|
||||
$parsed_url = parse_url( $file_url, PHP_URL_PATH );
|
||||
$extension = pathinfo( $parsed_url, PATHINFO_EXTENSION );
|
||||
|
||||
|
|
Loading…
Reference in New Issue