/demos/calendar/index.html
HTML | 121 lines | 92 code | 28 blank | 1 comment | 0 complexity | 23ad3bd0afbf2b9f7bc0c6874bd3b20b MD5 | raw file
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <title>jQueryMobile - DateBox Demos</title>
- <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0b2/jquery.mobile-1.0b2.min.css" />
- <link type="text/css" href="http://dev.jtsage.com/cdn/datebox/latest/jquery.mobile.datebox.min.css" rel="stylesheet" />
- <link type="text/css" href="http://dev.jtsage.com/jQM-DateBox/css/demos.css" rel="stylesheet" />
-
- <!-- NOTE: Script load order is significant! -->
-
- <script type="text/javascript" src="http://code.jquery.com/jquery-1.6.1.min.js"></script>
- <script type="text/javascript" src="http://code.jquery.com/mobile/1.0b2/jquery.mobile-1.0b2.min.js"></script>
- <script type="text/javascript" src="http://dev.jtsage.com/jquery.mousewheel.min.js"></script>
- <script type="text/javascript" src="http://dev.jtsage.com/cdn/datebox/latest/jquery.mobile.datebox.min.js"></script>
- <script type="text/javascript" src="http://dev.jtsage.com/gpretty/prettify.js"></script>
- <link type="text/css" href="http://dev.jtsage.com/gpretty/prettify.css" rel="stylesheet" />
- <script type="text/javascript">
- $('div').live('pagecreate', function() {
- prettyPrint()
- });
- </script>
-
- </head>
- <body>
- <div data-role="page" data-theme="a" id="calIndex">
- <div data-role="header">
- <h1>jQueryMobile - DateBox</h1>
- <a href="../../" data-icon="home" data-iconpos="notext">Home</a>
- </div>
- <div data-role="content" data-theme="c">
- <div class="content-secondary">
-
- <div id="jqm-homeheader">
- <h1 id="jqm-logo"><img src="/jQM-DateBox/demos/jquery-logo-db.png" alt="jQuery Mobile Framework :: DateBox" /></h1>
- <p>A Date and Time Picker plugin for jQueryMobile</p>
-
- </div>
-
- <ul data-role="listview" data-inset="true" data-theme="c" data-dividertheme="f">
- <li data-role="list-divider">Calendar Demos</li>
- <li data-theme='a'>Simple Calendars</li>
- <li><a href="limit.html">Range Limiting & Picking</a></li>
- <li><a href="blackhigh.html">Disabled & Highlighted Dates</a></li>
- </ul>
-
- </div><!--/content-primary-->
-
- <div class="content-primary">
- <nav>
- <h2>Basic Calendar</h2>
- <div data-role="fieldcontain">
- <label for="defcal">Some Date</label><input name="defcal" type="date" data-role="datebox" id="defcal" data-options='{"mode": "calbox"}'/>
- </div>
-
- <p>Using a calendar is as simple as setting the 'mode' option to "calbox".</p>
-
- <pre class="prettyprint"><label for="mydate">Some Date</label>
- <input name="mydate" id="mydate" type="date" data-role="datebox"
- data-options='{"mode": "calbox"}'></pre>
-
- <h2>Changing the start of the week</h2>
- <div data-role="fieldcontain">
- <label for="calstartday">Some Date</label><input name="calstartday" type="date" data-role="datebox" id="calstartday" data-options='{"mode": "calbox", "calStartDay": 1}'/>
- </div>
-
- <p>To change the start of the week, set option 'calStartDay' to an integer 0-6, where 0=Sunday, 1=Monday...</p>
-
- <pre class="prettyprint"><label for="mydate">Some Date</label>
- <input name="mydate" id="mydate" type="date" data-role="datebox"
- data-options='{"mode": "calbox", 'calStartDay': 1}'></pre>
-
- <h2>Selecting by week</h2>
- <div data-role="fieldcontain">
- <label for="calweekmode">Some Date</label><input name="calweekmode" type="date" data-role="datebox" id="calweekmode" data-options='{"mode": "calbox", "calWeekMode": true, "calWeekModeFirstDay": 1}'/>
- </div>
-
- <p>Using a calendar to select a specific day can be accomplished by setting option 'calWeekMode' to 'true' and 'calWeekModeFirstDay' to the day you wish to pick. For instance, to select by week using monday:</p>
-
- <pre class="prettyprint"><label for="mydate">Some Date</label>
- <input name="mydate" id="mydate" type="date" data-role="datebox"
- data-options='{"mode": "calbox", "calWeekMode": true, "calWeekModeFirstDay": 1}'></pre>
-
- <h2>Showing a "today" button</h2>
- <div data-role="fieldcontain">
- <label for="caltodaybut">Some Date</label><input name="caltodaybut" type="date" data-role="datebox" id="caltodaybut" data-options='{"mode": "calbox", "calTodayButton": true}'/>
- </div>
-
- <p>To show a today button, set 'calTodayButton' to true</p>
-
- <pre class="prettyprint"><label for="mydate">Some Date</label>
- <input name="mydate" id="mydate" type="date" data-role="datebox"
- data-options='{"mode": "calbox", 'calTodayButton': true}'></pre>
- <h2>Disabling manual input</h2>
- <div data-role="fieldcontain">
- <label for="caldisablemanualinput">Some Date</label><input name="caldisablemanualinput" type="date" data-role="datebox" id="caldisablemanualinput" data-options='{"mode": "calbox", "disableManualInput": true}'/>
- </div>
- <p>You're not able to type a value in the following input, you can set the value by the picker.</p>
- <pre class="prettyprint"><label for="mydate">Some Date</label>
- <input name="mydate" id="mydate" type="date" data-role="datebox"
- data-options='{"mode": "calbox", "disableManualInput": true}'></pre>
- </nav>
- </div>
-
- </div>
- <div data-role="footer">
- <div data-role="controlgroup" data-type="horizontal">
- <a data-role="button" href="https://github.com/jtsage/jquery-mobile-datebox">GitHub Source</a><a data-role="button" rel='external' href="http://dev.jtsage.com/blog/">Blog</a><a data-role="button" href="mailto:jtsage+datebox@gmail.com">Contact</a><a data-role="button" href="http://jquerymobile.com/">jQueryMobile Homepage</a>
- </div>
- </div>
- </div>
- </html>