PageSourceSearch

https://incorrys.com/wp/wp-content/plugins/memberpress/js/date_picker.js?ver=1.12.17

js incorrys.com collected 2026-09-24 08:44:16 UTC 1,961 bytes, 57 lines download raw bytes

1jQuery(document).ready(function($) {
2  //I guess these can be tweaked as time goes, but for now these seem like reasonable targets
3  var currentYear = new Date().getFullYear();
4  var pastYears = currentYear - 100;
5  var futureYears = currentYear + 50;
6
7  var dateFormat = 'yy-mm-dd';
8  var timeFormat = 'HH:mm:ss';
9  var showTime   = true;
10  var translations = {};
11  var options = {};
12
13  //Front End needs to display cleaner
14  if(typeof MeprDatePicker != "undefined") {
15    if(MeprDatePicker.hasOwnProperty('dateFormat')){
16      dateFormat = String(MeprDatePicker.dateFormat);
17    }
18    timeFormat = MeprDatePicker.timeFormat;
19    showTime = Boolean(MeprDatePicker.showTime);
20    translations = MeprDatePicker.translations;
21  }
22
23  if(typeof translations !== 'undefined' && translations != null) {
24      options = translations;
25  }
26
27  options['dateFormat'] = dateFormat;
28  options['timeFormat'] = timeFormat;
29  options['yearRange'] = pastYears + ":" + futureYears;
30  options['changeMonth'] = true;
31  options['changeYear'] = true;
32  options['showTime'] = showTime;
33  options['onSelect'] = function (date, inst) {
34      $(this).trigger('mepr-date-picker-selected', [date, inst]);
35    };
36  options['onChangeMonthYear'] = function (year, month, inst) {
37      if(year != inst.currentYear) {
38        $(this).datepicker( 'setDate', new Date(year, month-1, inst.selectedDay) );
39      }
40      $(this).trigger('mepr-date-picker-changed', [month, year, inst]);
41    };
42  options['onClose'] = function (date, inst) {
43      $(this).val(date.trim()); //Trim off white-space if any
44      $(this).trigger('mepr-date-picker-closed', [date, inst]);
45    };
46
47  $('.mepr-date-picker').each(function() {
48    var data = $(this).data();
49    var override = {};
50    // Override the options with the data attributes.
51    $.each(data, function(key, value) {
52      override[key] = value;
53    });
54    options = $.extend({}, options, override);
55    $(this).datetimepicker( options );
56  });
57});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.