From b172757a8e6cc5aa346fc747b8f38184e21dc3b6 Mon Sep 17 00:00:00 2001 From: Gerhard Date: Tue, 16 Apr 2013 09:01:50 +0200 Subject: [PATCH] Remove url params from filenames on orders in backend under Downloadable Product Permissions --- .../writepanels/order-download-permission-html.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/admin/post-types/writepanels/order-download-permission-html.php b/admin/post-types/writepanels/order-download-permission-html.php index 59971b865b6..2b107a768a5 100644 --- a/admin/post-types/writepanels/order-download-permission-html.php +++ b/admin/post-types/writepanels/order-download-permission-html.php @@ -6,7 +6,11 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
- id ) . ' — ' . apply_filters( 'woocommerce_admin_download_permissions_title', $product->get_title(), $download->product_id, $download->order_id, $download->order_key, $download->download_id ) . ' — ' . sprintf( __( 'File %d: %s', 'woocommerce' ), $file_count, basename( $product->get_file_download_path( $download->download_id ) ) ) . ' — ' . sprintf( _n('Downloaded %s time', 'Downloaded %s times', absint( $download->download_count ), 'woocommerce'), absint( $download->download_count ) ); ?> + get_file_download_path( $download->download_id ) ); + $filename = basename( $filename_parts['path'] ); + ?> + id ) . ' — ' . apply_filters( 'woocommerce_admin_download_permissions_title', $product->get_title(), $download->product_id, $download->order_id, $download->order_key, $download->download_id ) . ' — ' . sprintf( __( 'File %d: %s', 'woocommerce' ), $file_count, $filename ) . ' — ' . sprintf( _n('Downloaded %s time', 'Downloaded %s times', absint( $download->download_count ), 'woocommerce'), absint( $download->download_count ) ); ?>