jquery-ui-datepicker

jquery datepicker and custom validation

↘锁芯ラ 提交于 2019-12-21 05:31:47
问题 I need to add custom validation(I think) for validating input from an user. Here's my use case: I'm using the jquery ui datepicker for selecting dates, with localization like this: $.datepicker.setDefaults( $.datepicker.regional[ currentLocale ] ); I use the bassistance validation plugin, and using rules for date:true and such does not work with different formats(or if they do please tell me how!). So I've made my own date validation methods like this $.validator.addMethod("validDate",

Use jQuery DatePicker in Bootstrap 3 modal

做~自己de王妃 提交于 2019-12-21 03:10:07
问题 I would like to use jQuery UI datepicker in a modal. The real problem is that if I want to also show years and months, it shows me empty selects: Using firebug, it seems that the option tags are under the modal. This is my HTML: <div class="modal-dialog"> <div class="modal-content"> <form id="add-form" action="#" method="post"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> <h4 class="modal-title">Add</h4> </div> <div class=

jQuery UI datepicker performance

别说谁变了你拦得住时间么 提交于 2019-12-20 23:27:03
问题 I have a textbox on my web page that is used to specify a date, so I'd like to use the jQuery DatePicker. However, most of my users are locked into using IE6 and the performance of the jQuery DatePicker is a little sluggish in this browser. Can anyone recommend an alternate JavaScript date picker, or any means of improving the display performance of the jQuery DatePicker? 回答1: I also ran into this problem. Here are a couple of things that can help performance in IE6: Turn on background image

How to get a datepicker for Html.Editorfor

那年仲夏 提交于 2019-12-20 21:47:09
问题 On my MVC3 razor page I have a date field @Html.EditorFor(model => model.Member.Dob) Given below is the code I am trying to get a datepicker for the Date of Birth field. <script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script> <script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script> <link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>

How do I convert between date formats used by jquery ui datepicker and moment.js? [closed]

为君一笑 提交于 2019-12-20 15:28:54
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 6 years ago . The date formatting string has different rules in jQuery UI datepicker, moment.js, DateTime class from .Net. How do I convert between these different formats? Update: Now on github: https://github.com/deerchao/dateformats 回答1: Use the TypeScript version like this: var j =

How can i set Year range for a jQuery Date Picker: 1900 to current year, or 1900 to 9999

核能气质少年 提交于 2019-12-20 11:51:41
问题 Hi all i used the Jquery Date picker which works well enough for me. But i am having a small issue i.e i would like to set the Start year from 1900 and End year to Current Year or 9999 .. In the script i found this for year range yearRange: 'c-100:c+100' If i move forward to some thing like 1800 i am unable to see the current year .. What changes should i do here in order to see my years in a such a way that the years should be 1900-current year or 1900-9999 I tried this which works for me

jQuery: datepicker alternative

依然范特西╮ 提交于 2019-12-20 10:00:48
问题 Is there a better, smaller alternative to the jQuery datepicker? The ui.datepicker.js has app. 70kb which is pretty huge imo. Could it be compressed? 回答1: you don't need the whole ui library just http://jqueryui.com/download disable the other stuff or you can use google ajax api cdn. the best alternative to jui datepicker is the html5 datepicker with is only supported by opera so far <input type="datetime-local" /> 回答2: The best alternative I know is Kelvin luck's datepicker. 回答3: It's not

jQuery Datepicker - keep open after selecting a date and close with the button “Done”

廉价感情. 提交于 2019-12-20 06:39:19
问题 I honestly hope you can help me with that as I have spent quite some time searching on the net for appropriate solutions and could not find any. The issue I am having is that I have a jQuery datepicker which I would like to keep open after selecting a date and then close it when clicking the button "Done" underneath it. The closest thing I found is coming from a StackOverflow answer from 2012, but unfortunately it hides the buttons coming from the showButtonPanel: true option. So this is a

jquery mobile datebox custom alignment

天大地大妈咪最大 提交于 2019-12-20 06:28:54
问题 I am currently using jquery mobile datebox (http://dev.jtsage.com/jQM-DateBox/) to display a calendar. I stuck the input in a div with display: none, and then I manually activate the calendar with the following javascript: $('#opencalendarlink').live('click', function(){ $('#datepicker').datebox('open'); }); where opencalendarlink is the id of the button and date picker is the id of the calendar. However, the calendar appears now left aligned, although the button and corresponding hidden div

Can I make the jQuery datepicker display more year when using the changeYear option?

扶醉桌前 提交于 2019-12-20 06:23:38
问题 I am using the jQuery datepicker in an application which will be used, among other things, to insert and update birth dates of employees. I find it cumbersome to have to click several times in order to get to the 70's and 80', decades in which many employees are born in. Is there a way to access these 'further' years in less clicks? This is what my datepicker looks like $("#DateOpened").datepicker({ dateFormat: "mm/dd/yy", maxDate: "+0D", showAnim: 'slide', changeMonth: true, changeYear: true