rejetto forum

Software => HFS ~ HTTP File Server => Topic started by: Denis on January 25, 2011, 02:51:49 PM

Title: Folder size
Post by: Denis on January 25, 2011, 02:51:49 PM
Is there a method if users have there own folder, to limit the capacity? Like there folder can't get over, like 100 mb, or should you do this in windows?

Thanks!
Title: Re: Folder size
Post by: rejetto on January 25, 2011, 06:02:13 PM
there's nothing like that in HFS.
and despite it may be feasible to create it for a very skilled user, i guess you are quicker if your operating system can do it.
Title: Re: Folder size
Post by: Denis on January 26, 2011, 05:48:59 PM
Thanks!

Now i know if i should keep find a solution in HFS, or find another method.
I will try to limit the folder size in windows.

Thanks again, this was wery helpfull! :)
Title: Re: Folder size
Post by: Denis on February 11, 2011, 04:21:54 PM
Does anyone have a macro to do this, and how could i make a macro like that? :)
Title: Re: Folder size
Post by: rejetto on February 16, 2011, 02:35:19 PM
that's nothing to be explained in 5 minutes, you need to be a programmer. are you?
Title: Re: Folder size
Post by: Denis on February 19, 2011, 07:38:49 PM
Yes, i'm a programmer (a very good one  ::)). But don't know anything about macro. If there isn't anyone who can help me i'll do it myself :).
But stil thanks for the help.
And is there anyone who can help me find a good macro editor, and maybe a good website to learn it :).
Thanks for the help ;D.
Title: Re: Folder size
Post by: SilentPliz on February 19, 2011, 07:58:23 PM
There is no dedicated macro editor for HFS macros, I think. But you can use Notepad ++ or PSPad ... that can help.

For the rest, you will find here some usefull help here to answer your questions:

http://www.rejetto.com/wiki/index.php/HFS_Documentation_%28English%29
Title: Re: Folder size
Post by: rejetto on March 01, 2011, 02:02:45 PM
list of commands http://www.rejetto.com/wiki/index.php/HFS:_scripting_commands
you can work it out at different levels.
That's how i would go

1. replace the upload form with a code like this
IF %total-kbytes% > 100000
  upload space is over
ELSE
  the original form

2. add event
[upload completed]
IF calculated-space-of-this-dir > 100 MB
  {.delete|%item-resource%.}
  {.upload failed|Sorry, you ran out of space.}


if you want to go into this i'll help you more.
Your work will be easier with next release (275), i made some improvements towards it.