[wp-trac] [WordPress Trac] #16226: Attachment URL filenames are not urlencoded

WordPress Trac wp-trac at lists.automattic.com
Mon Feb 14 06:20:56 UTC 2011

#16226: Attachment URL filenames are not urlencoded
 Reporter:  mdawaffe      |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Future Release
Component:  Upload        |     Version:  3.1
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |

Comment (by solarissmoke):

 Replying to [comment:3 dd32]:
 > shouldn't % be encoded to %25 instead? ie. the filename should be

 The difficulty is urlencoding only the filename portion... we can't
 urlencode the whole url. And we can't do the encoding in
 `sanitize_file_name()` because that is used in other non-URL contexts. Is
 there some other place where it can be done?

Ticket URL: <http://core.trac.wordpress.org/ticket/16226#comment:4>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list