| CGI-FileUpload documentation | Contained in the CGI-FileUpload distribution. |
CGI::FileUpload::Manager - manipulating the list of CGI::FileUpload
brwose the working directory and build a list of CGI:FileUpload
Return an array (sorted by date) of upload file keys
Return an array (sorted by date) of upload file CGI::FileUpload objects
Alexandre Masselot, <alexandre.masselot at genebio.com>
Please report any bugs or feature requests to bug-cgi-fileupload at rt.cpan.org, or through
the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=CGI-FileUpload. I will be notified, and then you'll
automatically be notified of progress on your bug as I make changes.
You can find documentation for this module with the perldoc command.
perldoc CGI::FileUpload
You can also look for information at:
Copyright 2007 Alexandre Masselot, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
| CGI-FileUpload documentation | Contained in the CGI-FileUpload distribution. |
package CGI::FileUpload::Manager; use warnings; use strict;
use CGI::FileUpload; use File::Basename; use File::Glob qw(:glob); require Exporter; our (@ISA,@EXPORT,@EXPORT_OK); @ISA=qw (Exporter); @EXPORT=qw(&ls &lskey); @EXPORT_OK=qw(); sub lskey{ my %tmp; foreach(glob CGI::FileUpload::uploadDirectory()."/*.properties"){ my $k=basename($_); $k=~s/\.properties$//; $tmp{$k}=(stat($_))[9]; } return sort {$tmp{$b} <=> $tmp{$a}} keys %tmp; } sub ls{ my @keys=lskey(); my @ret; foreach(@keys){ push @ret, CGI::FileUpload->new(key=>$_); } return @ret; } 1;