Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Add a D7 version.
To start with, just implement a new element #type = "plupload" and have it behave pretty similarly to #type = 'file' just handle an upload with no bells or whistles. Also, write a callback to demonstrate it.
We could also do something like:
$form['myfile'] = array(
'#type' => 'file',
'#multiple' => TRUE,
);
and respond to that, but for now, just making a new element to KISS.
Comment | File | Size | Author |
---|---|---|---|
#11 | plupload.tokenconflict.patch | 1.97 KB | effulgentsia |
#8 | 880288-prepare-directory-8.patch | 3.19 KB | pwolanin |
#7 | 880288-prepare-directory-7.patch | 2.64 KB | pwolanin |
#6 | plupload_validation.patch | 14.41 KB | JacobSingh |
#5 | 880288-plupload-D7-4.patch | 14.68 KB | pwolanin |
Comments
Comment #1
JacobSingh CreditAttribution: JacobSingh commentedComment #2
pwolanin CreditAttribution: pwolanin commentedLooks like Jacob already committed the above to CVS.
Here's a follow-on patch that's mostly the work of effulgensia.
Comment #3
effulgentsia CreditAttribution: effulgentsia commentedsubscribe :)
Comment #4
pwolanin CreditAttribution: pwolanin commentedbased on http://www.plupload.com/punbb/viewtopic.php?pid=92#p92 and testing, it seems like session cookies do work with flash.
This patch adds flash back and adds a URL token.
Comment #5
pwolanin CreditAttribution: pwolanin commentedreordered the runtimes.
Comment #6
JacobSingh CreditAttribution: JacobSingh commentedThis patch by @efflugentsia and @pwolanin adds validators mainly, and encompasses pwolanin's patches above.
Committed to D7 and closing for now. New bugs and features in new issues. This has been tested by Acquia's QA team in multiple browsers / OSs
Comment #7
pwolanin CreditAttribution: pwolanin commentedQuick follow-up to make sure the temp directory exists and to fix up the code style in the handle_upload function.
Comment #8
pwolanin CreditAttribution: pwolanin commentedplus improved checking of the temp file name for security - we can't actually sanitize it, we just need to reject it if it's invalid.
Comment #9
effulgentsia CreditAttribution: effulgentsia commentedLooks good. As per #6, once this is fixed, let's stop using this generic issue, and open new issues for specific features/bugs/tasks.
Comment #10
effulgentsia CreditAttribution: effulgentsia commentedCommitted to CVS HEAD.
Comment #11
effulgentsia CreditAttribution: effulgentsia commentedCommitted this additional patch that fixes a token name conflict and temp directory variable bug.