Js multiple-choice date control and js multiple-choice control

Source: Internet
Author: User

Js multiple-choice date control and js multiple-choice control
Js multi-Choice Date Control

See http://www.lovewebgames.com/jsmodule/calendar.html for details

Its github address: https://github.com/tianxiangbing/calendar

 

Calendar

Js calendar Control

Usage
1 <input type = "text" id = "calendar" value = "2015-04-15"/> 2 <script src = ".. /src/jquery-1.9.1.min.js "> </script> 3 <script src = ".. /src/calendar. js "> </script> 4 <script> 5 var calendar = new Calendar (); 6 calendar. init ({7 target: $ ('# calendar'), 8 range: ['2014-3-5 ', '2014-3-25'], 9 multiple: true, 10 maxdays: 5, 11 overdays: function (a) {12 alert ('added to the upper limit '+ a + 'day'); 13} 14}); 15 </script>

 

Or
    <input type="text" class="calendar" value="2015-03-14"/>    <input type="text" class="calendar2" value="2015-03-18"/>    <script src="../dist/jquery-1.9.1.min.js"></script>    <script src="../dist/calendar-jquery.min.js"></script>    <script>        $(".calendar").Calendar({toolbar:true});        $(".calendar2").Calendar();    </script>

  

Property and method property date:
Current date.
Toolbar: bool
Show the operation column below
Separator:
Date separator. Default Value "-".
Id:
Calendar container ID
CalendarContainer:
Calendar container object
DayArr:
['Day', 'yi', '2', '3', '4', '5', '6']
MonthArr:
", "August October", "August November", "August December"]
IsShow: whether to display maxdays: the maximum number of days when multiple options are selected. setRange: function (range)
Method for setting the optional date range
Init: function (settings) settings parameter focusDate:
Selected Date }}
Target:
The event node that triggers the calendar. It can be input or other labels. If it is input, the value is used as the focusDate by default. Otherwise, the value of the previous input of the target or the current time is used.
Selected: function (a, B)
The selected callback event. The parameter is a time object and a calendar container.
BeforeSelect: function (a, B)
Select the trigger method, the parameter is (a) time object, (B) calendar container
Overdays: function (daysnum)
Callback when the specified number of days is exceeded (select multiple times)
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.