@Mars: Finally, I've got the time to test your change in the template code.
I've changed the code a little bit (marked in red) to generate a "normal" MD5 file (compatible with any external MD5 reader, like
HashCheck v2.1.11)
Here is...
[upload-success]
{.inc|ok.}
{.comment|Reset md5 var.}
{.set|md5.}
<li> <a href="%item-url%">%item-name%</a>
<br />%item-size% @ %smart-speed%B/s
{.if|{.>|%item-size%|0.}|{:
{.comment|Calculate md5.}
{.set|md5|{.md5 file|%item-resource%.}.}
{.comment|Create a new md5 file.}
{.save|%item-resource%.md5|{.^md5.} *%item-name%.}
{.comment|View md5 on Upload Result.}
<br />MD5 : {.^md5.}
:}.}
{.if| {.length|%user%.} |{: {.comment|.append|%folder-resource%\hfs.comments.txt |{.filename|%item-resource%.}=uploaded by %user%
/append.}
{.set item|%item-url%|comment=uploaded by %user%.}
:}/if.}
Everything seems to work fine, but I have a problem in the generated MD5 file. Imagine I have a file called:
"Rock & Roll.zip" (or any file containing the "&" character). Using the code above (with the change marked in red), that generates an invalid MD5 file (I mean, a md5 file which can't be read by an external MD5 reader, like HashCheck v2.1.11). The problem is the "&" character in the filename. I've tried several options:
{.save|%item-resource%.md5|{.^md5.} *%item-name%.}
That generates the following MD5 File (it contains "
&" which makes the problem):
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF *Rock & Roll.zip {.save|%item-resource%.md5|{.^md5.} *%item-resource%.}
That generates the following MD5 File (the file name now is OK, but an MD5 must not have the full path):
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF *C:\SharedFolder\Music\Rock & Roll.zip {.save|%item-resource%.md5|{.^md5.} *%filename%.extension.}
That generates the following MD5 File (non valid file name):
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF *%filename%.extensionIn my example, a correct MD5 file should look like this:FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF *Rock & Roll.zipWhat I need to change to make it work?...