WordPress.org

Make WordPress Core

Changeset 7631


Ignore:
Timestamp:
04/08/08 17:22:20 (7 years ago)
Author:
ryan
Message:

Strip percent signs when sanitizing filenames so the server doesn't try to decode entities. Props filosofo. fixes #5587 for trunk

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/functions.php

    r7508 r7631  
    11431143 
    11441144        $filename = str_replace( $ext, '', $filename ); 
    1145         $filename = sanitize_title_with_dashes( $filename ) . $ext; 
     1145        // Strip % so the server doesn't try to decode entities. 
     1146        $filename = str_replace('%', '', sanitize_title_with_dashes( $filename ) ) . $ext; 
    11461147 
    11471148        while ( file_exists( $dir . "/$filename" ) ) { 
Note: See TracChangeset for help on using the changeset viewer.