Merge pull request #7747 from woothemes/allow-paths-in-file-urls

Allowed paths for file url
This commit is contained in:
Mike Jolley 2015-03-17 17:28:55 +00:00
commit 7f1f8054ce
1 changed files with 1 additions and 1 deletions

View File

@ -1233,7 +1233,7 @@ class WC_Meta_Box_Product_Data {
for ( $i = 0; $i < $file_url_size; $i ++ ) {
if ( ! empty( $file_urls[ $i ] ) ) {
$file_url = 0 === strpos( $file_urls[ $i ], '[' ) ? wc_clean( $file_urls[ $i ] ) : esc_url_raw( $file_urls[ $i ] );
$file_url = ( 0 === strpos( $file_urls[ $i ], '[' ) && 0 !== strpos( $file_urls[ $i ], 'http' ) ) ? wc_clean( $file_urls[ $i ] ) : esc_url_raw( $file_urls[ $i ] );
$file_name = wc_clean( $file_names[ $i ] );
$file_hash = md5( $file_url );
$files[ $file_hash ] = array(