View Single Post
Old 04-13-2006, 02:38 PM  
jeza
Senior Member
 
jeza's Avatar
 
Join Date: May 2003
Posts: 530
Default

Quote:
Originally Posted by devereuxx
hello.
I wonder if its possible 2 make a script or something that can append the username to the dirname when u make a new dir.
fe. user1 logins and makes a new dir called "test123" in my ul dir, i would like the name 2become "test123(user1)".

//devereux

ioFTPD.ini
[FTP_Post-Command_Events]
mkd = TCL jScripts.itcl NEWDIR

put this code to file jScripts.itcl and add it to your ioFTPD/system dir
Code:
regsub -all -- {\\} $path {/} path
if { [file exists "$path/[lindex $args 2]"] } {
	catch { [file rename -force -- "$path/[lindex $args 2]" "$path/[lindex $args 2]($user)"] }
}
rehash/restart ioftpd
jeza is offline   Reply With Quote