container.html 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1">
  6. <title>Pikaday - Container example</title>
  7. <meta name="author" content="Stuart McFarlane">
  8. <link rel="stylesheet" href="../css/pikaday.css">
  9. <link rel="stylesheet" href="../css/site.css">
  10. </head>
  11. <body>
  12. <a href="https://github.com/dbushell/Pikaday"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png" alt="Fork me on GitHub"></a>
  13. <h1>Pikaday - Container example</h1>
  14. <p class="large">A refreshing JavaScript Datepicker — lightweight, no dependencies, modular CSS.</p>
  15. <div>
  16. <div class="flow-element">
  17. <label for="datepicker">Date:</label>
  18. <input type="text" id="datepicker">
  19. </div>
  20. <div class="flow-element">
  21. <div id="container"></div>
  22. </div>
  23. </div>
  24. <h2>What is this?</h2>
  25. <p>Since version 1.0 Pikaday is a stable and battle tested date-picker. Feel free to use it however you like but please report any bugs or feature requests to the <a href="https://github.com/dbushell/Pikaday/issues">GitHub issue tracker</a>, thanks!</p>
  26. <p class="small">Copyright © 2014 <a href="http://dbushell.com/">David Bushell</a> | BSD &amp; MIT license | Example by <a href="https://github.com/rikkert">Ramiro Rikkert</a></p>
  27. <!-- First load pikaday.js and then the jQuery plugin -->
  28. <script src="../pikaday.js"></script>
  29. <script>
  30. var picker = new Pikaday(
  31. {
  32. field: document.getElementById('datepicker'),
  33. firstDay: 1,
  34. minDate: new Date(2000, 0, 1),
  35. maxDate: new Date(2020, 12, 31),
  36. yearRange: [2000, 2020],
  37. bound: false,
  38. container: document.getElementById('container'),
  39. });
  40. </script>
  41. </body>
  42. </html>