Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
bootstrap3 input file test
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>bootstrap3のinput[file]のテスト</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css">
</head>
<body>
<div class="container">
<h1>bootstrap3のinput[file]のテスト</h1>
<form class="form-horizontal">
<div class="form-group">
<label class="col-md-2 control-label" for="file_a">ファイルA</label>
<div class="col-md-10">
<input class="form-control" id="file_a" type="file">
<span class="help-block"><code>form-control</code>付き</span>
</div>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="file_b">ファイルB</label>
<div class="col-md-10">
<input class="form-control" id="file_b" type="file" style="line-height:1">
<span class="help-block"><code>form-control</code>と<code>line-height:1</code>付き</span>
</div>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="file_c">ファイルC</label>
<div class="col-md-10">
<input id="file_c" type="file">
<span class="help-block"><code>form-control</code>なし</span>
</div>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="file_d">ファイルD</label>
<div class="col-md-10">
<input id="file_b" type="file" style="line-height:1">
<span class="help-block"><code>line-height:1</code>付き</span>
</div>
</div>
</form>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.