「Html/bootstrap/日付ライブラリ」の版間の差分
提供: 初心者エンジニアの簡易メモ
行2: | 行2: | ||
http://eternicode.github.io/bootstrap-datepicker/ | http://eternicode.github.io/bootstrap-datepicker/ | ||
− | ==使い方== | + | ==使い方== |
+ | <nowiki><</nowiki>div class="form-group"> | ||
+ | <input type="text" class="form-control datepicker" /> | ||
+ | </div> | ||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script> | <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script> | ||
<link rel="stylesheet" type="text/css" href="/assets/bootstrap-datepicker-1.6.1-dist/css/bootstrap-datepicker.min.css"> | <link rel="stylesheet" type="text/css" href="/assets/bootstrap-datepicker-1.6.1-dist/css/bootstrap-datepicker.min.css"> | ||
<script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/js/bootstrap-datepicker.min.js"></script> | <script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/js/bootstrap-datepicker.min.js"></script> | ||
<script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/locales/bootstrap-datepicker.ja.min.js"></script> | <script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/locales/bootstrap-datepicker.ja.min.js"></script> | ||
− | |||
− | |||
− | |||
<script type="text/javascript"> | <script type="text/javascript"> | ||
$('.datepicker').datepicker({ | $('.datepicker').datepicker({ |
2016年8月11日 (木) 07:19時点における版
公式
http://eternicode.github.io/bootstrap-datepicker/
使い方
<div class="form-group">
<input type="text" class="form-control datepicker" /> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script> <link rel="stylesheet" type="text/css" href="/assets/bootstrap-datepicker-1.6.1-dist/css/bootstrap-datepicker.min.css"> <script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/js/bootstrap-datepicker.min.js"></script> <script type="text/javascript" src="/assets/bootstrap-datepicker-1.6.1-dist/locales/bootstrap-datepicker.ja.min.js"></script> <script type="text/javascript"> $('.datepicker').datepicker({ format: "yyyy/mm/dd", language: "ja", autoclose: true, orientation: "top auto" }); </script>