rejetto forum
Software => HFS ~ HTTP File Server => Topic started by: artem78 on December 16, 2015, 10:29:04 PM
-
Some files on my server contains non ascii (cyrillic) symbols in name. How can I create a macros to transliterate it when downloading? Maybe it possible to add header "Content-Disposition: attachment; filename=NewFileName"?
-
HFS the program itself can't handle some of the file names. if the file name has non utf-8 characters in it, HFS will be unable to send the file
there have been many users having issues, it a know bug/problem that doesn't have an easy or viable solution.
Meaning you have to use file names that contain alpha number numbers "a-z" 0-1"... :(
BUT, you can try with other html conventional means that change the language and encoding type:
Example:
http://www.w3.org/International/questions/qa-html-encoding-declarations.en
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
Since you are using ascii, you can try it, but there is no guarantee:
http://winrus.com/cpage_e.htm
http://winrus.com/mix_e.htm
http://www.w3schools.com/charsets/
I would recommend this for you:
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-8">
Here is a helpful site that can help translate/encode for possible html support via meta tags:
(you would have to copy and paste it over back and forth manually ... :(
http://mashke.org/Conv/
good luck
-
it can be done: access the "events" and add one called [download name] as reported in the documentation
http://www.rejetto.com/wiki/index.php?title=HFS:_Event_scripts
if you do something like this
[download name]
(%item-name%)
you should get all files surrounded with parenthesis, for example.
Now you also need the command to replace characters, and it's {.replace.}
see documentation http://www.rejetto.com/wiki/index.php?title=HFS:_scripting_commands#Data_manipulation