AnyEvent-HTTPD-ExtDirect
view release on metacpan or search on metacpan
lib/AnyEvent/HTTPD/ExtDirect.pm view on Meta::CPAN
my $is_form = $req->param('extAction') && $req->param('extMethod');
# If form is not involved, it's easy: just return raw POST (or undef)
if ( !$is_form ) {
my $postdata = $req->content;
return $postdata ne '' ? $postdata
: undef
;
};
# If any files are attached, extUpload field will be set to 'true'
my $has_uploads = $req->param('extUpload') eq 'true';
# Outgoing hash
my %keyword;
# Pluck all parameters from the Request object
for my $param ( $req->params ) {
my @values = $req->param($param);
$keyword{ $param } = @values == 0 ? undef
: @values == 1 ? $values[0]
( run in 0.467 second using v1.01-cache-2.11-cpan-e1769b4cff6 )