Ignore:
Timestamp:
2009-01-06T19:03:58+13:00 (15 years ago)
Author:
ak19
Message:

Now plugins provide the option of base64 encoding or url encoding filenames that are to be renamed (when copied into the archives dir). Previously renamed files would always be url-encoded. URL-encoding is the default now for most plugins except MP3Plugin and OggVorbisPlugin, where the default is base64 encoding. Base64 encoding filenames upon renaming them was introduced so that more files that browsers try to open in external applications can open them, since url encoding does not seem to be implemented the same everywhere (for instance, windows media player is unable to handle url-encoded wmv filenames when such files are launched in it through the browser).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gsdl/trunk/perllib/plugins/ImagePlugin.pm

    r17666 r18320  
    114114    if ($self->{'image_conversion_available'} == 1) {
    115115    my $utf8_filename_no_path = $self->filepath_to_utf8($filename_no_path);
    116     my $url_encoded_filename = &unicode::url_encode($utf8_filename_no_path);
     116    my $url_encoded_filename = &util::rename_file($utf8_filename_no_path, $self->{'file_rename_method'});
    117117    $self->generate_images($filename_full_path, $url_encoded_filename, $doc_obj, $doc_obj->get_top_section()); # should we check the return value?
    118118    } else {
Note: See TracChangeset for help on using the changeset viewer.