Changeset 16956


Ignore:
Timestamp:
2008-08-21T16:36:57+12:00 (16 years ago)
Author:
ak19
Message:

Associated file names are url-encoded

File:
1 edited

Legend:

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

    r16921 r16956  
    106106    $doc_obj->add_metadata($top_section, "srcicon", "<img src=\"_httpprefix_/images/irmvideo.gif\" title=\"Download\" border=0>");
    107107
    108     # Add the actual filename as it exists on the file system as an associated file
    109     # by making sure we undo any URL-encoding escaping there may be
    110     $filename_no_path =~ s/%25/%/g;
    111     $doc_obj->associate_file($filename_full_path, $filename_no_path, "RealMedia", $top_section);
     108    # Add the actual filename as it exists on the file system (URL-encoded) as an
     109    # associated file by making sure we undo any escaped URL-encoding there may be
     110    my $assoc_file = $doc_obj->get_assocfile_from_sourcefile(); # just url-encoded filename, no path
     111    $doc_obj->associate_file($filename_full_path, $assoc_file, "RealMedia", $top_section);
    112112
    113113}
Note: See TracChangeset for help on using the changeset viewer.