Para::Frame::Uploaded - Class for uploaded files
Uploaded files are taken care of in Para::Frame::Client
They are temporarily saved in /tmp/paraframe/
. The filename is the
client process id followed by the fieldname with nonalfanum chars
removed. The file is deleted directly after the request!
Use /save_as to store the file.
Example:
$req->uploaded('filefield')->save_as($destfile);
Para::Frame::Uploaded->new($fieldname)
Called by Para::Frame::Request/uploaded.
Returns: The Para::Frame::Uploaded object
$uploaded->save_as( $destfile ) $uploaded->save_as( $destfile, \%args )
Copies the file to $destfile
.
SCP is supported. You can use //host/path
or //user@host/path
.
For SCP, $args->{username}
is used if set.
Returns: $uploaded
$uploaded->fh $uploaded->fh( $mode )
Creates and returns an IO::File object
$uploaded->info $uploaded->info( $item )
Returns a hash from CGI uploadInfo()
, ot the specified $item
.
$uploaded->content_type
Returns the best guess of the content type. It may be taken from /info or the file extension or the internal content of the file.
$uploaded->tempfile
Retuns a Para::Frame::File of the temporary file, that will be removed after this request.
$uploaded->tempfilename
Retuns the filename of the temporary file, that will be removed after this request.
Jonas Liljegren E<lt>jonas@paranormal.seE<gt>
L<Para::Frame>