rejetto forum
Software => HFS ~ HTTP File Server => Topic started by: gauravforyouall on February 13, 2009, 09:36:40 PM
-
Hi. i would like to know that if it is possible to rename file when user is downloading that
Like suppose file name is 1.mp3 i want to rename it as 1.1 or 1.2 or anyother thing just when user is renaming it.
-
i'm not sure i understand your need.
you can add 1.mp3 to HFS, then virtually rename it to 1.1
the physical file will stay the same, but it will appear and be downloaded as 1.1
-
exactly, this is what i want but i dont want to rename all files myself, as i have lot of files isnt there some way by which files are automaticlly renamed on downloading
-
renamed automatically by which rule?
-
By say number of downloads or any rule, or any fixed file name only let it be getfile.
-
hfs has not a feature to let you specify a different name for the same file at every download.
-
I love this software
-
thank you :)
-
could you please tell me how to do that? i mean automatically renaming file i am very bad in scripts and i dont follow anything related to this :( so i will need help
-
maybe you misread my previous post: hfs has NOT such feature.
but....wait, it is possible, by making a script associated to the [download completed].
but it will have to physically rename the file.
it takes some time to make it, and i have no time now. i hope someone else will enjoy making the script for you.
-
Ohok thanks a lot ! This software is good!
-
Rejetto related to this topic some how
is it possible that hfs willrename file when user download it
like file is added to HFS as Linkin_Park.mp3 and when user download andsave it it goes to 1.mp3 as a default name right?
cant HFS rename the file(or say add website/host name or other predefined word) and send download to user for example Linkin_Park_rejetto.com.mp3
Possible?
-
at the moment HFS can only rename the file, cannot change the name of the download itself.
is it so useful?
-
Ya. it would be very useful that if it change name on download .............
-
i meant: if you mind explaining me why it is, i can consider adding it to the to-do-list
-
Oh... I misunderstood your question ;D ya, many a times we need to transfer files and they are blocked due to security reasons or any other firewall and mostly they check it by their extension only not by the file header so we need to do it manual rename on each file and then reciever can change extension later on... If that is automatic it would be helpful . Like me , i need to transfer daily around 90-100 files over network as my project is music based and my educaitonal institute firewall doesnt allows music files to be transfered i need to rename them all so ...
-
Oh... I misunderstood your question ;D ya, many a times we need to transfer files and they are blocked due to security reasons or any other firewall and mostly they check it by their extension only not by the file header so we need to do it manual rename on each file and then reciever can change extension later on... If that is automatic it would be helpful . Like me , i need to transfer daily around 90-100 files over network as my project is music based and my educaitonal institute firewall doesnt allows music files to be transfered i need to rename them all so ...
...Create a zip file with a password (so that cannot be opened) to transfer that many files into one step ;)
-
:( suppose i have 10000 files or more and i dont know which will be downloaded that can be any na... :( i cant create and save each as ZIP
-
:( suppose i have 10000 files or more and i dont know which will be downloaded that can be any na... :( i cant create and save each as ZIP
Sorry, as you wrote "I have to transfer daily 90~100 files" I though you know which files :)
You can create a script to rename all the files when you "publish" them (something like copy *.mp3 *.mp_ ) so that they are not blocked anymore
-
i will work on it
-
no so important but just ...
mm like we are sharing things for nothing ... so what if our site name goes with file name even i know 90% ppls rename the file
-
You can create a script to rename all the files when you "publish" them (something like copy *.mp3 *.mp_ ) so that they are not blocked anymore
in your template, have a look at the section [upload-success]
replace all the section with:
[upload-success]
<li>
{.set|newfilename|{.replace|.oldtxt|.mp3|%item-name%.}.}
{.if not|{.=|%item-name%|{.^newfilename.}.}|{:{.rename|%item-resource%|{.replace|%item-name%|{.^newfilename.}|%item-resource%.}.}:}.}
<a href='{.replace|%item-name%|{.^newfilename.}|%item-url%.}'>{.^newfilename.}</a>: <b>{.!OK.}</b> --- %item-size% ({.!Speed.} %speed% KB/s)
{.if| %user% |{: {.append| %folder-resource%\hfs.comments.txt |{.filename|%item-resource%.}=uploaded by %user%
/append.} :}/if.}
all uploaded files with the ext .oldext are renamed to .mp3 at every upload. you have only to change the .oldext by your one in the code.
-
ahh you got us wrong, solution is for uploading of files ? correct uploading aint in the picture it is just say i have folder abc, in that i ahve files 1.mp3, 2.mp3,3.mp3 i want when i put folder abc on share using hfs it shld so files as 1.anything,2.anything,3.anything to any user viewing or trying to downlaod it. I appreciate your effort for making upload script
-
the solution you search: when you add a folder abc, you can use a DOS command:
c:\.....\abc>Ren *.mp3 *.anything
-
again.... I dont want to rename it on my pc ! Like you can rename a single file virtually in HFS manually by pressing F2 over file i want that task to be automatic. I
-
good news for you.
from version 2.3 build #224 you will be able to just put this code in event scripts (ALT+F6)
[download name]
{.replace|.mp3|.mp_|%item-name%.}
-
i am waiting !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!11 :)
-
i am waiting !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!11
gauravforyouall show a little respect. No need to write something like that. Didn't rejetto's reply above answer your question?
-
thank you maverick, but i guess g. was not claiming, but just expressing excitement :)
what he overlooked is that the build was published just 10 minutes after my post, so he waiting for nothing :)