[wp-trac] [WordPress Trac] #14627: wp_handle_upload unique_filename_callback problem
WordPress Trac
wp-trac at lists.automattic.com
Fri Sep 10 06:59:44 UTC 2010
#14627: wp_handle_upload unique_filename_callback problem
--------------------------+-------------------------------------------------
Reporter: xiosen | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Upload | Version: 3.0.1
Severity: major | Keywords: needs-patch
--------------------------+-------------------------------------------------
Comment(by mikeschinkel):
I just found the exact same thing! Line 2218 in v3.0.1 of `/wp-
includes/functions.php` has the following code:
{{{
$filename = $unique_filename_callback( $dir, $name );
}}}
This is all that would be needed to "fix" this problem:
{{{
$filename = $unique_filename_callback( $dir, $name, $ext );
}}}
Adding a third parameter would enable a developer to return a working
file.
As it, the 'unique_filename_callback' is pretty much unusable. This is
teeny, tiny fix, please accept for v3.1.
-Mike
--
Ticket URL: <http://core.trac.wordpress.org/ticket/14627#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list