RESOLVED WONTFIX 18957
Allow assignment to value attr of input[type=file] elements via ObjC DOM API
https://bugs.webkit.org/show_bug.cgi?id=18957
Summary Allow assignment to value attr of input[type=file] elements via ObjC DOM API
Todd Ditchendorf
Reported 2008-05-08 16:51:46 PDT
Given an HTML element in a DOM: <input type="file"> AFAICT, you cannot programmatically set the value of the "value" attribute of this element via the ObjC DOM API. I understand that JavaScript is not allowed to set the value of the "value" attr due to security restrictions. But it seems that ObjC should be allowed to set this value attribute, as it wouldn't be a security risk, no? thx!
Attachments
Todd Ditchendorf
Comment 1 2008-05-08 16:55:31 PDT
My use case: I am writing a WebKit-based desktop application, and I want users to be able to easily drag a local file to anywhere on the WebView, to add the file as the value of the 'value' attr of an <input type="file"> element in the current DOM. I know that you can currently drop a file directly over the input element, but that *does* require a bit more dexterity, and does not work in the case where the input element may be currently hidden or scrolled out of view. This enhancement would allow me to offer nicer usability.
mitz
Comment 2 2008-05-08 18:27:50 PDT
Maybe this can be better served by (extensions to) the DOM drag and drop API.
Mark Rowe (bdash)
Comment 3 2008-05-08 23:46:59 PDT
Ahmad Saleem
Comment 4 2022-08-11 10:06:44 PDT
There are various enhancements in WebAPI and JavaScript use cases and in general across browsers, I think this can be achieved easily these days and this enhancement request can be marked as "RESOLVED WONTFIX". Please reopen, if you think there is still gap in modern Web standards to achieve this and you can also raise such discussion of gaps in Standards or related WHATWG Github. Thanks!
Note You need to log in before you can comment on or make changes to this bug.