8 Einträge, 1 Seite |
1
2
3
4
5
6
7
8
<html>
<head></head>
<body>
<form name="form1" enctype="multipart/form-data" method="post" action="">
<input type="file" name="file" onChange="alert(this.value)">
</form>
</body>
</html>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/perl
use strict;
use warnings;
use File::Find;
print "Content-type: text/html\n\n";
my $startdir = '/path/to/startdirectory';
my @dirs;
find(\&find_dirs,$startdir);
print_select(\@dirs);
sub find_dirs{
push(@dirs,$File::Find::name) if(-d $File::Find::name);
}# find_dirs
sub print_select{
my ($dir_ref) = @_;
print "<select><option>".join('</option><option>', @$dir_ref).'</option></select>';
}
8 Einträge, 1 Seite |