summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/forms/file/file-input-disabled.html
blob: 42baaee41875bd7a1284eadf9e03eee6789400ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<html>
<head>
<title>Testing disabling file input</title>

<script language="JavaScript" type="text/javascript">
<!--
function checkboxClicked(element) {
	if (element.checked) {
		document.getElementById("file_input").disabled = false;
	} else {
		document.getElementById("file_input").disabled = true;
	}
}
//-->
</script>
</head>
<body>
<form>
<table>
<input name="attach_screenshot" type="checkbox" onClick="checkboxClicked(this);">
<b>Attach File</b><br><br>
&nbsp;&nbsp;Select File:&nbsp;
<input id="file_input" name="thumbnail_file" type="file" disabled="true"><br>
</form>
</body>
</html>