Open Bug 399917 Opened 17 years ago Updated 2 years ago

Allow pasting and drag-dropping of file names into a file input

Categories

(Core :: Layout: Form Controls, defect)

defect

Tracking

()

People

(Reporter: roc, Unassigned)

References

Details

See https://bugzilla.mozilla.org/show_bug.cgi?id=258875#c134

Pasting and drag-dropping of file names into a file input control should open the file picker, defaulting to that name.
Not to be confused with drag-dropping of actual files, which is covered by bug 50660 and might not use the same UI as dragging file names.
Surely it is a significant UI regression from FF2 that you can no longer paste into a file upload field and this should be fixed for FF3?

I understand the security issues that required making the field not directly pasteable (as annoying as I may find it that I can no longer do that) but it seems that the workaround described here is the best we're going to get going forward so it really should be implemented so that *something* happens when you middle click on the upload field...
Flags: blocking1.9?
Flags: blocking1.9? → blocking1.9-
Opening a filepicker is safer than simply selecting the file (which would reopen bug 57770). But I have a few concerns:

* Which OSes let us pre-select items in native file pickers?

* Native file pickers don't have anti-clickjacking timers, because they are not typically used as security confirmation dialogs. So like in bug 162020, a malicious site would just have to convince you to press Enter or click a certain spot immediately after pasting/dropping.

* Users won't carefully check that the pre-selected file is the one they intended to upload, because they aren't expecting clipboard shenanigans.
Another possibility is to open a file browser (e.g. Finder) with the file pre-selected. You could then drag the file to the page. But that's a lot more clicking and dragging, especially if the windows overlap.
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.