+%} elsif ( $opt{'process_upload'} and @uploaded_files ) {
+%
+% # construct a form to pass all the requested fields, the
+%
+<& /elements/header.html &>
+<form name="UploadForm">
+% my $job_fields = $opt{'process_upload'}{'fields'};
+% foreach my $field ( @$job_fields ) {
+ <input type="hidden" name="<% $field %>" value="<% $cgi->param($field) |h %>">
+% }
+% push @$job_fields, 'uploaded_files', $pkey;
+%
+ <input type="hidden" name="uploaded_files" value="<% join(',', @uploaded_files) %>">
+ <input type="hidden" name="<% $pkey %>" value="<% $new->get($pkey) %>">
+<& /elements/progress-init.html,
+ 'UploadForm',
+ $job_fields,
+ $fsurl . $opt{'process_upload'}{'process'},
+ {
+ url => $redirect,
+ error_url => "$error_redirect?$new_pkey"
+ },
+&>
+<input type="submit" style="display:none">
+</form>
+<script>
+<&| /elements/onload.js &>
+process();
+</&>
+</script>
+<& /elements/footer.html &>
+