Issue 124957 in chromium: File open dialog not opened with hidden "<input type=file/>" tag

19 views
Skip to first unread message

chro...@googlecode.com

unread,
Apr 24, 2012, 11:48:48 PM4/24/12
to chromi...@chromium.org
Status: Unconfirmed
Owner: ----
Labels: Type-Bug Pri-2 Area-Undefined OS-Windows

New issue 124957 by chaitany...@gmail.com: File open dialog not opened with
hidden "<input type=file/>" tag
http://code.google.com/p/chromium/issues/detail?id=124957

Chrome Version : 18.0.1025.162
OS Version: 5.1 (Windows XP)
URLs (if applicable) :
Other browsers tested:
Add OK or FAIL after other browsers where you have tested this issue:
Safari 5:
Firefox 4.x:
IE 7/8/9:

What steps will reproduce the problem?
1. Run below html code in chrome.
<html>
<script type="text/javascript">
function select_file()
{
var file = document.getElementsByName("s_file");
file[0].click();
}
function upload()
{
alert("In Upload") ;
}
</script>
<body>
<form enctype="multipart/form-data" method="post">
<input type="button" value="Click!" onclick="select_file()"/>
<input type="file" style="display:none" name="s_file" onchange="upload()"/>
</form>
</body>
</html>

2.Click on the button named 'Click!'.

What is the expected result?

File open dialog should open up. The above code works with firefox and IE

What happens instead?

Nothing has happened.

Please provide any additional information below. Attach a screenshot if
possible.

UserAgentString: Mozilla/5.0 (Windows NT 5.1) AppleWebKit/535.19 (KHTML,
like Gecko) Chrome/18.0.1025.162 Safari/535.19

Attachments:
file.html 432 bytes

chro...@googlecode.com

unread,
Apr 25, 2012, 11:06:40 PM4/25/12
to chromi...@chromium.org
Updates:
Status: Duplicate
Mergedinto: 78961

Comment #1 on issue 124957 by tk...@chromium.org: File open dialog not
opened with hidden "<input type=file/>" tag
http://code.google.com/p/chromium/issues/detail?id=124957

(No comment was entered for this change.)

Reply all
Reply to author
Forward
0 new messages