Rev 2497 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2497 | Rev 15421 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | !if $abandon!=$empty |
1 | !if $abandon!=$empty |
2 | job=fs |
2 | job=fs |
3 | !changeto $job.proc |
3 | !changeto $job.proc |
4 | !endif |
4 | !endif |
5 | 5 | ||
6 | c=!char 1 of $file |
6 | c=!char 1 of $file |
7 | !if $c=/ |
7 | !if $c=/ |
8 | file=!char 2 to -1 of $file |
8 | file=!char 2 to -1 of $file |
9 | !endif |
9 | !endif |
10 | 10 | ||
11 | !if $job2=download |
11 | !if $job2=download |
12 | job2= |
12 | job2= |
13 | fname=!translate internal / to , in $file |
13 | fname=!translate internal / to , in $file |
14 | fname=!item -1 of $fname |
14 | fname=!item -1 of $fname |
15 | !sh cd $wims_home\ |
15 | !sh cd $wims_home\ |
16 | mkdir -p $wims_sesdir/getfile\ |
16 | mkdir -p $wims_sesdir/getfile\ |
17 | rm -f $wims_sesdir/getfile/$fname\ |
17 | rm -f $wims_sesdir/getfile/$fname\ |
18 | ln -s $wims_home/$file $wims_sesdir/getfile |
18 | ln -s $wims_home/$file $wims_sesdir/getfile |
19 | download=yes |
19 | download=yes |
20 | !endif |
20 | !endif |
21 | 21 | ||
22 | !read dir-modifiable |
22 | !read dir-modifiable |
23 | modifok=no |
23 | modifok=no |
24 | !for d in $modifiable |
24 | !for d in $modifiable |
25 | !if ../$d/ isin ../$file |
25 | !if ../$d/ isin ../$file |
26 | modifok=yes |
26 | modifok=yes |
27 | break |
27 | break |
28 | !endif |
28 | !endif |
29 | !next d |
29 | !next d |
30 | 30 | ||
31 | ftype=!exec ftype $wims_home/$file |
31 | ftype=!exec ftype $wims_home/$file |
32 | ext=!translate internal . to , in $file |
32 | ext=!translate internal . to , in $file |
33 | ext=!item -1 of $ext |
33 | ext=!item -1 of $ext |
34 | ext=!tolower $ext |
34 | ext=!tolower $ext |
35 | !if $ext iswordof gif png mng jpg jpeg |
35 | !if $ext iswordof gif png mng jpg jpeg |
36 | ftype=image |
36 | ftype=image |
37 | !if ../public_html/ isin ../$file |
37 | !if ../public_html/ isin ../$file |
38 | pubimg=!replace internal ../public_html/ by $ in ../$file |
38 | pubimg=!replace internal ../public_html/ by $ in ../$file |
39 | !endif |
39 | !endif |
40 | !endif |
40 | !endif |
41 | 41 | ||
42 | !if $modifok=yes and $job2=eraseconfirm |
42 | !if $modifok=yes and $job2=eraseconfirm |
43 | job2= |
43 | job2= |
44 | !sh cd $wims_home; rm -f $file |
44 | !sh cd $wims_home; rm -f $file |
45 | job=fs |
45 | job=fs |
46 | !changeto $job.proc |
46 | !changeto $job.proc |
47 | !endif |
47 | !endif |
48 | 48 | ||
49 | !if $modifok=yes and $save!=$empty |
49 | !if $modifok=yes and $save!=$empty |
50 | !sh cd $wims_home\ |
50 | !sh cd $wims_home\ |
51 | [ -f $wims_sesdir/user-deposit ] && cp $wims_sesdir/user-deposit $file |
51 | [ -f $wims_sesdir/user-deposit ] && cp $wims_sesdir/user-deposit $file |
52 | job=fs |
52 | job=fs |
53 | !changeto $job.proc |
53 | !changeto $job.proc |
54 | !endif |
54 | !endif |
55 | 55 | ||
56 | fstat=!sh stat -c "%s,%y,%A" $wims_home/$file |
56 | fstat=!sh stat -c "%s,%y,%A" $wims_home/$file |
57 | !distribute item $fstat into flen,fdat,facc |
57 | !distribute item $fstat into flen,fdat,facc |
58 | fdat=!word 1 of $fdat |
58 | fdat=!word 1 of $fdat |
59 | 59 | ||
60 | !if $modifok=yes and $job2=erase |
60 | !if $modifok=yes and $job2=erase |
61 | job2= |
61 | job2= |
62 | erase=ask |
62 | erase=ask |
63 | !exit |
63 | !exit |
64 | !endif |
64 | !endif |
65 | - | ||
66 | - |