vs cqueryvs2010 打开 dialogg是什么类

关于CTabCtrl中对话框的位置调整,卡了两天了,救救我吧 setwindowpos与movewindow_百度知道Show | jQuery UI
Display elements using custom effects.
Click the button above to preview the effect.
&!doctype html& lang=&en&&&
charset=&utf-8&&
name=&viewport& content=&width=device-width, initial-scale=1&&
&jQuery UI Effects - Show Demo&
rel=&stylesheet& href=&///ui/1.12.1/themes/base/jquery-ui.css&&
rel=&stylesheet& href=&/resources/demos/style.css&&
.toggler { width: 500 height: 200 }
#button { padding: .5em 1 text-decoration: }
#effect { width: 240 height: 170 padding: 0.4 position: }
{ margin: 0; padding: 0.4 text-align: }
src=&/jquery-1.12.4.js&&&
src=&/ui/1.12.1/jquery-ui.js&&&
$( function() {
function runEffect() {
var selectedEffect = $( &#effectTypes& ).val();
var options = {};
if ( selectedEffect === &scale& ) {
options = { percent: 50 };
} else if ( selectedEffect === &size& ) {
options = { to: { width: 280, height: 185 } };
$( &#effect& ).show( selectedEffect, options, 500, callback );
function callback() {
setTimeout(function() {
$( &#effect:visible& ).removeAttr( &style& ).fadeOut();
}, 1000 );
$( &#button& ).on( &click&, function() {
runEffect();
$( &#effect& ).hide();
class=&toggler&&
id=&effect& class=&ui-widget-content ui-corner-all&&
class=&ui-widget-header ui-corner-all&&Show&
Etiam libero neque, luctus a, eleifend nec, semper at, lorem. Sed pede. Nulla lorem metus, adipiscing ut, luctus sed, hendrerit vitae, mi.
name=&effects& id=&effectTypes&&
value=&blind&&Blind&
value=&bounce&&Bounce&
value=&clip&&Clip&
value=&drop&&Drop&
value=&explode&&Explode&
value=&fade&&Fade&
value=&fold&&Fold&
value=&highlight&&Highlight&
value=&puff&&Puff&
value=&pulsate&&Pulsate&
value=&scale&&Scale&
value=&shake&&Shake&
value=&size&&Size&
value=&slide&&Slide&&
id=&button& class=&ui-state-default ui-corner-all&&Run Effect&
Want to learn more about the .show() method? Check out(DLG)是什么意思
[问题点数:30分,结帖人weisieo]
(DLG)是什么意思
[问题点数:30分,结帖人weisieo]
不显示删除回复
显示所有回复
显示星级回复
显示得分回复
只显示楼主
2006年11月 VC/MFC大版内专家分月排行榜第二
2006年7月 VC/MFC大版内专家分月排行榜第三2006年6月 VC/MFC大版内专家分月排行榜第三
2006年11月 VC/MFC大版内专家分月排行榜第二
2006年7月 VC/MFC大版内专家分月排行榜第三2006年6月 VC/MFC大版内专家分月排行榜第三
本帖子已过去太久远了,不再提供回复功能。Zebra_Datepicker, a lightweight datepicker jQuery plugin
Latest version
released on
Zebra_Datepicker is a small, compact and highly configurable datepicker jQuery plugin, meant to enrich forms by adding the datepicker functionality to them. This jQuery plugin will automatically add a calendar icon to the indicated input fields
which, when clicked, will open the attached datepicker. Users can easily jump between months and years due to the datepicker’s intuitive interface. The selected date will be entered in the input field using the date format of choice, configurable in the datepicker’s options.
it is small – it weights around 23KB minified
it’s compact – unlike other datepickers, this datepicker is one-file only
it’s cross-browser – works in works also in Internet Explorer 6 where it uses an iFrameShim to stay above select controls
it’s compatible with AMD and CommonJS
has a default color scheme that blends-in well with almost any design, and it’s easily customizable through the well-organized CSS two additional themese are included, one of them being for use with
offers an intuitive interface fast and easy navigation through months and years
offers an intuitive mechanism for disabling dates and date ranges using a syntax similar to cron‘s syntax
supports defining of custom weekend days for countries that don’t have the weekend on Saturday and Sunday
supports most of date formats you can think of, borrowing the syntax of PHP’s date function
supports all sorts of combinations for starting and ending dates
date pickers can be “paired” – where one or more date pickers will use the value of another date picker as starting date
supports internationalization
works by automatically attaching a small calendar icon to the indicated input fields which displays the attached datepicker when clicked.
Thanks to Aeron Glemann for building a datepicker for MooTools where he came up with the idea of disabling dates using a syntax similar to cron’s!
Requirements
Zebra_Datepicker has no dependencies other than jQuery 1.5.2+ but requires that the page you are using the plugin on to have a strict doctype like
&!doctype html&
How to use
First, load the latest version of jQuery either from a local source or from a CDN.
Load the Zebra_Datepicker jQuery plugin
&script type="text/javascript" src="path/to/zebra_datepicker.js"&&/script&
Load one of the available themes (default, metallic, bootstrap)
&link rel="stylesheet" href="path/to/default.css" type="text/css"&
Now, within the DOM-ready event, attach the Zebra_Datepicker plugin to a &input type=”text”& control
$(document).ready(function() {
// assuming the controls you want to attach the plugin to
// have the "datepicker" class set
$('input.datepicker').Zebra_DatePicker();
This will attach a calendar icon to the specified element(s). Clicking the icon, will make the date picker visible.
To get a reference to the instance of Zebra_DatePicker attached to an element do:
var $zdp = $('#element').data('Zebra_DatePicker');
1. A date picker with defaults settings.
$('#datepicker-example1').Zebra_DatePicker();
2. Dates can be selected only in the future, starting one day in the future.
$('#datepicker-example2').Zebra_DatePicker({
direction: 1
// boolean true would've made the date picker future only
// but starting from today, rather than tomorrow
3. Dates can be selected only in the future, starting today. Also, Saturday and Sundays are always disabled.
$('#datepicker-example3').Zebra_DatePicker({
direction: true,
disabled_dates: ['* * * 0,6']
// all days, all monts, all years as long
// as the weekday is 0 or 6 (Sunday or Saturday)
4. The selectable dates are in the interval starting tomorrow and ending 10 days from tomorrow.
$('#datepicker-example4').Zebra_DatePicker({
direction: [1, 10]
5. Dates can be selected between 2 specific dates
$('#datepicker-example5').Zebra_DatePicker({
// remember that the way you write down dates
// depends on the value of the "format" property!
direction: ['', '']
6. Dates can be selected in the future, starting with a specific date
$('#datepicker-example6').Zebra_DatePicker({
// remember that the way you write down dates
// depends on the value of the "format" property!
direction: ['', false]
7. The second date picker’s starting date is the value of the first date picker + 1
$('#datepicker-example7-start').Zebra_DatePicker({
direction: true,
pair: $('#datepicker-example7-end')
$('#datepicker-example7-end').Zebra_DatePicker({
direction: 1
8. Set the format of the returned date:
$('#datepicker-example8').Zebra_DatePicker({
format: 'M d, Y'
9. Show week number
$('#datepicker-example9').Zebra_DatePicker({
show_week_number: 'Wk'
10. Start with the “years” view – recommended for when users need to select their birth date. Remember that you can always switch between views by clicking in the header of the date picker between the “previous” and “next” buttons!
$('#datepicker-example10').Zebra_DatePicker({
view: 'years'
11. Stop after month selection
$('#datepicker-example11').Zebra_DatePicker({
format: 'm Y'
note that becase there's no day in the format
users will not be able to select a day!
12. Handle the “onChange” event. If a callback function is attached to the “onChange” event, it will be called whenever the user changes the view (days/months/years), as well as when the user navigates by clicking on the “next”/”previous” icons in any of the views. The callback function called by this event takes two arguments – the view (days/months/years) and the “active” elements (not disabled) in that view, as jQuery elements allowing for easy customization and interaction with particular cells in the date picker’s view:
$('#datepicker-example12').Zebra_DatePicker({
// execute a function whenever the user changes the view (days/months/years),
// as well as when the user navigates by clicking on the "next"/"previous"
// icons in any of the views
onChange: function(view, elements) {
// on the "days" view...
if (view == 'days') {
// iterate through the active elements in the view
elements.each(function() {
// to simplify searching for particular dates, each element gets a
// "date" data attribute which is the form of:
// - YYYY-MM-DD for elements in the "days" view
// - YYYY-MM for elements in the "months" view
// - YYYY for elements in the "years" view
// so, because we're on a "days" view,
// let's find the 24th day using a regular expression
// (notice that this will apply to every 24th day
// of every month of every year)
if ($(this).data('date').match(/\-24$/))
// and highlight it!
$(this).css({
backgroundColor:
'#C40000',
13. Calendar is always visible. Set the “always_visible” property to point to a jQuery
element which to contain the date picker
$('#datepicker-example13').Zebra_DatePicker({
always_visible: $('#container')
14. Using data attributes
Any property of the date picker can also be set via data-attributes. All you have to do is take any property described in the “Configuration” section and prefix it with “data-zdp_”. One important thing to remember is that if the value of the property is an array you’ll have to use double quotes inside the square brackets and therefore single quotes around the attribute – see the example below:
&input type="text" id="datepicker-example14"
data-zdp_direction="1" data-zdp_disabled_dates='["* * * 0,6"]'>
$('#datepicker-example14').Zebra_DatePicker();
Configuration
All parameters are optional.
Note that any of the properties below may also be set via HTML5 data attributes. To do this you have prefix the name of the property you want to set with “data-zdp_”. One important thing to remember is that if the value of the property is an array you’ll have to use double quotes inside the square brackets and therefore single quotes around the attribute. See example 14 from above.
always_visible
Should the date picker be always visible?&
Setting this property to a jQuery element will result in the date picker being always visible, the indicated element acting as the date picker’
By default, the date picker is injected into the &body&; use this property to tell the library to inject the date picker into a custom element – useful when you want the date picker to open at a specific position.
Must be a jQuery element
Default is $(‘body’)
custom_classes
Dates that should have custom classes applied to them.
An object in the form of
'myclass1': [dates_to_apply_the_custom_class_to],
'myclass2': [dates_to_apply_the_custom_class_to]
…where “dates_to_apply_the_custom_class_to” is an array of dates in the same format as required for “disabled_dates” property.
Custom classes will be applied only in the day picker view and not on month/year views! Also note that the class name will have the “_disabled” suffix added if the day the class is applied to is disabled
In order for the styles in your custom classes to be applied, make sure you are using the following syntax:
.Zebra_DatePicker .dp_daypicker td.myclass1 { .. }
.Zebra_DatePicker .dp_daypicker td.myclass1_disabled { .. }
default is FALSE, no custom classes
Days of the week. Sunday to Saturday.
Default is
[‘Sunday’, ‘Monday’, ‘Tuesday’, ‘Wednesday’, ‘Thursday’, ‘Friday’, ‘Saturday’]
Abbreviated names of days.
By default, the abbreviated name of a day consists of the first 2 letters from the day’s full name. While this is common for most languages, there are also exceptions for languages like Thai, Loa, Myanmar, etc. where this is not correct. For these cases, specify an array with the abbreviations to be used for the 7 leave it FALSE to use the first 2 letters of a day’s name as the abbreviation.
Default is FALSE
default_position
The position of the date picker relative to the element it is attached to.
Note that, regardless of this setting, the date picker’s position will be automatically adjusted to fit in the view port, if needed.
Possible values are “above” and “below”.
Default is “above”
This property will be ignored if always_visible or container properties are set!
Direction of the calendar.
A positive or negative integer: n (a positive integer) creates a future-only calendar beginning a -n (a negative integer) creates a past-only calendar ending if n is 0, the calendar has no restrictions. use boolean true for a future-only calendar starting with today and use boolean false for a past-only calendar ending today.
You may also set this property to an array with two elements in the following combinations:
– first item is boolean TRUE (calendar starts today), an integer > 0 (calendar starts n days after today), or a valid date given in the format defined by the “format” attribute (calendar starts at the specified date), and the second item is boolean FALSE (the calendar has no ending date), an integer > 0 (calendar ends n days after the starting date), or a valid date given in the format defined by the “format” attribute and which occurs after the starting date (calendar ends at the specified date)
– first item is boolean FALSE (calendar ends today), an integer
0 (calendar ends n days before the ending date), or a valid date given in the format defined by the “format” attribute and which occurs before the starting date (calendar starts at the specified date)
[1, 7] – calendar starts tomorrow and ends seven days after that
[true, 7] – calendar starts today and ends seven days after that
[&#-01’, false] – calendar starts on January 1st 2013 and has no ending date (“format” is YYYY-MM-DD)
[false, &#-01’] – calendar ends today and starts on January 1st 2012 (“format” is YYYY-MM-DD)
Note that “disabled_dates” property will still apply!
Default is 0 (no restrictions).
disabled_dates
An array of disabled dates in the following format: ‘day month year weekday’ where “weekday” is optional and can be 0-6 (Saturday to Sunday); The syntax is similar to cron’s syntax: the values are separated by spaces and may contain * (asterisk) – (dash) and , (comma) delimiters:&
[&# ;] would disable January 1, 2012;
[‘* 1 ;] would disable all days in January 2012;
[&# 1 ;] would disable January 1 through 10 in 2012;
[&# 1 ;] would disable January 1 and 10 in 2012;
[&#,20,22,24 1-3 *’] would disable 1 through 10, plus the 22nd and 24th of January through M
[‘* * * 0,6′] would disable all Saturdays and S
[&# ;, &# ;, ‘* 08 ;] would disable 1st and 2nd of July 2012, and all of August of 2012
Default is FALSE, no disabled dates.
DISABLING ALL DATES AND NOT SPECIFYING AT LEAST ONE ENABLED DATE WILL SEND THE SCRIPT INTO AN INFINITE LOOP SEARCHING FOR AN ENABLED DATE TO DISPLAY!
enabled_dates
An array of enabled dates in the same format as required for “disabled_dates” property. To be used together with the “disabled_dates” property by first setting the “disabled_dates” property to something like “[* * * *]” (which will disable everything) and the setting the “enabled_dates” property to, say, “[* * * 0,6]” to enable just weekends.
Default is FALSE.
first_day_of_week
Week’s starting day.&
Valid values are 0 to 6, Sunday to Saturday.
Default is 1, Monday.
Format of the returned date.&
Accepts the following characters for date formatting: d, D, j, l, N, w, S, F, m, M, n, Y, y borrowing syntax from (PHP’s
function).
Note that when setting a date format without days (‘d’, ‘j’), the users will be able to select only years and months, and when setting a format without months and days (‘F’, ‘m’, ‘M’, ‘n’, ‘t’, ‘d’, ‘j’), the users will be able to select only years.
Also note that the value of the “view” property (see below) may be overridden if it is the case: a value of “days” for the “view” property makes no sense if the date format doesn’t allow the selection of days.
Default is ‘Y-m-d’.
header_captions
Captions in the datepicker’s header, for the 3 possible views: days, months, years&
For each of the 3 views the following special characters may be used borrowing from PHP’s “date” function’s syntax: m, n, F, M, y and Y; any of these will be replaced at runtime with the appropriate date fragment, depending on the currently viewed date. two more special characters are also available Y1 and Y2 (upper case representing years with 4 digits, lowercase representing years with 2 digits) which represent “currently selected year  and “currently selected year + 4” and which only make sense used in the “years” view.
Even though any of these special characters may be used in any of the 3 views, you should use m, n, F, M for the “days” view and y, Y, Y1, Y2, y1, y2 for the “months” and “years” view or you may get unexpected results!
Text and HTML can also be used, and will be rendered as it is, as in the example below (the library is smart enough to not replace special characters when used in words or HTML tags):
header_captions: {
'Departure:&br&F, Y',
'Departure:&br&Y',
'Departure:&br&Y1 - Y2'
Default is
header_captions: {
header_navigation
HTML to be used for the previous month/next month buttons&
default is [‘«’,’»’]
icon_position
Icon’s position
Accepted values are “left” and “right”
Default is “right”.
Should the icon for opening the datepicker be inside the element?&
If set to FALSE, the icon will be placed to the right of the parent element, while if set to TRUE it will be placed to the right of the parent element, but *inside* the element itself
Default is TRUE.
lang_clear_date
the caption for the “Clear” button.&
Months names.&
Default is
[‘January’, ‘February’, ‘March’, ‘April’, ‘May’, ‘June’, ‘July’, ‘August’, ‘September’, ‘October’, ‘November’, ‘December’],
months_abbr
Abbreviated names of months.
By default, the abbreviated name of a month consists of the first 3 letters from the month’s full name. While this is common for most languages, there are also exceptions for languages like Thai, Loa, Myanmar, etc. where this is not correct. For these cases, specify an array with the abbreviations to be used for th leave it FALSE to use the first 3 letters of a month’s name as the abbreviation.
Default is FALSE
The offset, in pixels (x, y), to shift the date picker’s position relative to the top-right of the icon that toggles the date picker or, if the icon is disabled, relative to the top-right corner of the element
the plugin is attached to.&
Note that this only applies if the position of element relative to the browser’s viewport doesn’t require the date picker to be placed automatically so that it is visible!
Default is [5, -5].
open_icon_only
When set to TRUE, the date picker will show only when users click on the associated icon, and not also when clicking the associated element
Default is FALSE
If set as one or more jQuery elements with Zebra_Datepicker attached, those particular date pickers will use the current date picker’s value as starting date&
Note that the rules set in the “direction” property will still apply, only that the reference date will not be the current system date but the value selected in the current date picker.
Default is FALSE (not paired with another date picker)
readonly_element
Should the element the calendar is attached to, be read-only?&
If set to TRUE, a date can be set only through the date picker and cannot be entered manually.
Default is TRUE.
select_other_months
Should days from previous and/or next month be selectable when visible?&
Note that if the value of this property is set to TRUE, the value of “show_other_months” will be considered TRUE regardless of the actual value!
Default is FALSE.
show_clear_date
Should the “Clear date” button be visible?&
Accepted values are:
– 0 (zero) – the button for clearing a previously selected date is shown only if a previously selected this means that if the input the date picker is attached to is empty, and the user selects a date for the first time, this button once the user picked a date and opens the date picker again, this time the button will be visible.
– TRUE will make the button visible all the time
– FALSE will disable the button
Default is  (without quotes)
Should a calendar icon be added to the elements the plugin is attached to?&
When set to TRUE the plugin will attach a calendar icon to the elements the plugin is attached to.
Default is TRUE.
show_other_months
should days from previous and/or next month be visible?&
Default is TRUE.
show_select_today
Should the “Today” button be visible?&
Setting this property to anything but a boolean FALSE will enable the button and will use the property’s value as ca setting it to FALSE will disable the button
Default is “Today”.
show_week_number
Should an extra column be shown, showing the number of each week?&
Anything other than FALSE will enable this feature, and use the given value as column title. For example, show_week_number: ‘Wk’ would enable this feature and have “Wk” as the column’s title.
Default is FALSE.
start_date
A default date to start the date picker with&
Must be specified in the format defined by the “format” property, or it will be ignored!
Note that this value is used only if there is no value in the field the date picker is attached to!
Default is FALSE.
Should default values, in the input field the date picker is attached to, be deleted if they are not valid according to “direction” and/or “disabled_dates”?
Default is FALSE.
How should the date picker start:&
Valid values are “days”, “months” and “years”.
Note that the date picker is always cycling days-months-years when clicking in the date picker’s header, and years-months-days when selecting dates (unless one or more of the views are missing due to the date’s format)
Also note that the value of the “view” property may be overridden if the date’s format requires so! (i.e. “days” for the “view” property makes no sense if the date format doesn’t allow the selection of days)
Default is “days”.
weekend_days
Days of the week that are considered “weekend days”&
Valid values are 0 to 6, Sunday to Saturday.
Default is [0,6] (Saturday and Sunday).
Should day numbers < 10 be padded with zero?
When set to TRUE, day numbers < 10 will be prefixed with 0.
Default is FALSE.
Callback to be executed whenever the user changes the view (days/months/years), as well as when the user navigates by clicking on the &#8220;next&#8221;/&#8221;previous&#8221; icons
The callback function called by this event takes 3 arguments &#8211; the first argument represents the current view (can be &#8220;days&#8221;, &#8220;months&#8221; or &#8220;years&#8221;), the second argument represents an array containing the &#8220;active&#8221; elements (not disabled) from the view, as jQuery elements, allowing for easy customization and interaction with particular cells in the date picker&#8217;s view, while the third argument is a reference to the element the date picker is attached to, as a jQuery object.
For simplifying searching for particular dates, each element gets a &#8220;date&#8221; data attribute whose format depends on the value of the &#8220;view&#8221; argument:
&#8211; YYYY-MM-DD for elements in the &#8220;days&#8221; view
&#8211; YYYY-MM for elements in the &#8220;months&#8221; view
&#8211; YYYY for elements in the &#8220;years&#8221; view
Here&#8217;s how we could highlight the 24th day of each month of each year:
$('element').Zebra_DatePicker({
// execute a function whenever the user changes the view
//(days/months/years), as well as when the user
// navigates by clicking on the "next"/"previous" icons
// in any of the views
onChange: function(view, elements) {
// on the "days" view...
if (view == 'days') {
// iterate through the active elements in the view
elements.each(function() {
// to simplify searching for particular dates,
// each element gets a "date" data attribute which
// is the form of:
// - YYYY-MM-DD for elements in the "days" view
// - YYYY-MM for elements in the "months" view
// - YYYY for elements in the "years" view
// so, because we're on a "days" view,
// let's find the 24th day using a regular
// expression (notice that this will apply to
// every 24th day of every month of every year)
if ($(this).data('date').match(/\-24$/))
// and highlight it!
$(this).css({
backgroundColor:
'#C40000',
Callback function to be executed when the user clicks the &#8220;Clear&#8221; button.
The callback function takes a single argument:
&#8211; a reference to the element the date picker is attached to, as a jQuery object (deprecated &#8211; use the &#8220;this&#8221; keyword inside the callback function to refer to the element the date picker is attached to)
Callback function to be executed when the date picker is closed
The callback function takes a single argument:
&#8211; a reference to the element the date picker is attached to, as a jQuery object (deprecated &#8211; use the &#8220;this&#8221; keyword inside the callback function to refer to the element the date picker is attached to)
Callback function to be executed when the date picker is shown
The callback function takes a single argument:
&#8211; a reference to the element the date picker is attached to, as a jQuery object (deprecated &#8211; use the &#8220;this&#8221; keyword inside the callback function to refer to the element the date picker is attached to)
Callback function to be executed when a date is selected&
The callback function takes 4 parameters:
&#8211; the date in the format specified by the &#8220;format&#8221;
&#8211; the date in YYYY-MM-DD format
&#8211; the date as a JavaScript Date object
&#8211; a reference to the element the date picker is attached to, as a jQuery object
First, get a reference to the plugin like
var datepicker = $('element').data('Zebra_DatePicker');
Then call a method like
datepicker.update();
clear_date
Clears the selected date (if any)
Removes the plugin from an element
Sets the value of the element the date picker is attached to, t
The date must be in the format defined by the &#8220;format&#8221; property.
The date will not be set if it is disabled (either by &#8220;disabled_dates&#8221; or because of &#8220;direction&#8221;)
Shows the date picker (unless the &#8220;always_visible&#8221; property is set to TRUE)
Hides the date picker (unless the &#8220;always_visible&#8221; property is set to TRUE)
Updates configuration options at run-time, and recalculates date picker&#8217;s icon position relative to the parent element. You should call this method whenever you show/hide/reposition the parent element, or alter the parent element&#8217;
The method accepts an optional argument &#8211; an object with configuration options to update:
var datepicker = $('element').data('Zebra_DatePicker');
datepicker.update({
direction: 1
If you just want to update the icon&#8217;s position, simply call the method without any arguments:
var datepicker = $('element').data('Zebra_DatePicker');
datepicker.update();
If you find this library to be useful to you, you can support the author by donating a small amount via PayPal:
Alternatively, you could show your support by starring this library on GitHub
You may also like:Zebra_Accordion, a tiny Zebra_Cookie, an extremely small Zebra_Datepicker, a lightweight Zebra_Dialog, a lightweight Zebra_Pin, a lightweight Zebra_Tooltips, a lightweight Zebra_TransForm, a tiny
Click on a version to expand/collapse information.
version 1.9.4 (January 25, 2016)
images now have their own folder instead of being mixed
thanks to Maxime Pasquier
icon position can now be also set to the thanks to Jennifer for suggesting
added possibility to easily apply custom classes to date ranges
see the newly added custom_classes thanks to M?rt Tibar for suggesting
the library is now also available as a
fixed a bug that made impossible to install the library via
version 1.9.3 (January 11, 2016)
when the &#8220;value&#8221; attribute of the element is set, use that instead of &#8220;start_date&#8221;; thanks Vojtěch Biberle
fixed a bug where &#8220;header_navigation&#8221;, &#8220;lang_clear_date&#8221; and &#8220;show_select_today&#8221; properties could not be updated via the &#8220;update&#8221; thanks André Fiedler
fixed a bug where the paired date picker was not updated when users would manually enter a date in t thanks Toby for reporting
icon position is now updated when changing orientati thanks to chenghong for suggesting
added &#8220;clear_date&#8221; and &#8220;set_date&#8221; thanks Jason Davis for suggesting
added new &#8220;open_icon_only&#8221; property which, when set to TRUE, will result in the date picker showing *only* when users click on the associated icon, and not on element focus
dates prior to year 1000 are now disabled as this library cannot handle years below 1000
better comnonjs- thanks Stefan Schult
version 1.9.2 (April 30, 2015)
fixed bug with the &#8220;views&#8221; property which was not working anymore since
thanks to DJM75 for reporting!
version 1.9.1 (April 13, 2015)
fixed an issue where having more date pickers on a page and destroying one of the date pickers would remove the event handlers for all date thanks to lpproulx for reporting
date pickers can now also be injecte previously date picker were always injected in the
very useful if you want the date picker to always open at thanks to Daniel Ivan for suggesting
the library is now compatible with AMD and CommonJS; thanks to Andrzej Du?
added a new &#8220;onClose&#8221; thanks to W. van Kuipers
added touchstart event for closing the date picker on a touchev thanks W. van Kuipers
increased zIndex value to 1200, making the date picker usable with Twitter Bootstrap&#8217; thanks to Kiswono Prayogo
better fix for the issues in Firefox, solved in previous release, which made transitions thanks to René Jackowski
version 1.9.0 (November 14, 2014)
added some CSS attributes for the main table, in order to override defaults se thanks to Paul Morganthall
added a new &#8220;default_position&#8221; property, useful for setting whether the date picker should, by default, appear above or below the eleme
fixed an issue in latest versions of Firefox in which, even though the date picker is absolutely positioned, it takes up thanks to Joost
fixed a bug with paired date pickers where the second date picker&#8217;s range was not depending on the first date picker&#8217;s date unless a date in the first date picker was manually selected, and thus ignorin thanks to Pascal Lindelauf;
fixed a bug with highlighting months where in &#8220;months&#8221; view, if current date was higher than the number of days in February, the month woul thanks to Mark Tuor;
fixed a bug with where if a text box a date picker is attached to would be disabled at run-time, the date picker&#8217;s calendar icon would remain &#8220;enabled&#8221; after calling the &#8220;update&#8221; thanks to Frans
datepicker visibility is now controlled from CSS;
fixed an issue because of which the library was not compatible with jQuery 1.5.2+ (as stated) but required jQuery 1.7+ thanks to Martin Gaedeke for spotting it and to Prakhar Birla
version 1.8.9 (May 20, 2014)
added a new &#8220;header_captions&#8221; property, useful for customizing captions in the datepicker&#8217;s header, for the 3 possible views: days, months, thanks to Lodewyk and Ram
added a new &#8220;onOpen&#8221; event for executing callback functions when the
users can now always use the next/ thanks to Mozart
the &#8220;this&#8221; keyword in callbacks now correctly refer to the element the datep thanks to syahman
when having a date formats without year, the &#8220;years&#8221; view will no thanks to MarkG;
the &#8220;onSelect&#8221; callback takes an extra argument &#8211; the ISO 8601 week number
fixed a bug when having non ASCII chara thanks to straightdog and Muhobrc for reporting, and to D-ominik
fixed an issue with the &#8220;pair&#8221; attribute which, when given as a data attribute, would cause a JavaS thanks to Domenico Giambra;
fixed a bug with the iFrame shim in IE6 which was not working as expected and &#8220;selects&#8221; elements where shown a thanks to chenghong
fixed a minor bug where the date picker would close for any key press not just for the ESC thanks to nacho
fixed a minor bug where, when looking at the &#8220;months&#8221; view, the selected month would always be highlighted even if the use thanks to Yoyee Zhu
updated jQuery version in the examples folder to 1.11.1;
version 1.8.8 (December 09, 2013)
added integration with
the library is now available as a
version 1.8.7 (November 28, 2013)
added a new &#8220;header_navigation&#8221; property allowing custom HTML for the next/pre thanks to norlin;
fixed a minor bug with
version 1.8.6 (October 05, 2013)
added a new &#8220;strict&#8221; property which controls whether default values, in the input field the date picker is attached to, should be deleted if they are not valid according to &#8220;direction&#8221; and/or &#8220;disabled_dates&#8221;, and which is set to FALSE previously the plugin was always thanks Morten;
fixed a bug width selectable dates of other months than the current one having an incorrect cl
thanks to Khoomei for spotting this!
fixed a bug where when clearing dates of always-visible datepickers, the class indicating the &#8220;selected&#8221; state of cells w
removed some old code that was used back when the calendar icon was absolutely positioned and because of which the calendar icon was invisible if the parent element was placed in a parent element with &#8220;display: none&#8221;; thanks to Michael Residori;
updated jQuery version used in examples to 1.10.2;
version 1.8.5 (September 21, 2013)
properties can now be set thanks to Yuriy Silvestrov who suggested
fixed a bug where if the &#8220;show_icon&#8221; property was set to FALSE an open date picker would not close upon window resize and therefore it would remain in an incorrect position if the parent element was to change positio thanks Marco;
version 1.8.4 (August 11, 2013)
added a &#8220;destroy&#8221; thanks TeckniX;
date picker now disappear previously it would remain in the same position upon window resize, even though the parent element could be reposit thanks hanneslinder;
fixed a position bug that appearing in newer versions of Firefox where Firefox sets the &#8220;display&#8221; property of &input& elements to &#8220;inline&#8221; instead of &#8220;inline-block&#8221; as d thanks to discotizer;
version 1.8.3 (August 04, 2013)
fixed a bug where the plugin would freeze for certain combinations of disabled/ thanks Yogesh;
fixed a bug where having two paired date picker with &#8220;direction&#8221; set to FALSE, the second date picker will not obey this rule once a date is selected in t thanks Shane M;
fixed a bug where when having paired date pickers, the &#8220;Today&#8221; button was sometimes available although it shouldn&#8217; thanks Matt;
fixed some indenting issues and the sco thanks W. van Kuipers;
fixed a few minor issues reported by JSFiddle&#8217;s JSH
minor update of source code regarding optimal usage of jQuery for creating the wrapper aroun
version 1.8.2 (July 02, 2013)
fixed a bug where the calendar icon was in fact tak due to this I completely changed the way the calendar icon is placed and hopefully I didn&#8217;t brake it completely ?
the date picker&#8217;s &#8220;update&#8221; method is now automatically called upon page resize and thus taking care of the case when the date picker is attached to an element part of a fluid design
version 1.8.1 (June 29, 2013)
fixed a small bug where setting the &#8220;show_other_months&#8221; property to FALSE and having a full empty row of cells would result in the cells having the wrong height
version 1.8.0 (June 28, 2013)
fixed a bug where deciding whether the &#8220;next&#8221; and &#8220;previous&#8221; buttons should be shown, the script was not always thanks jojo;
fixed a bug where the date picker was not working in IE8 thanks sascha and Souli
fixed a bug in the &#8220;metallic&#8221;
added a new property called &#8220;show_select_today&#8221; which when set to TRUE allows for quick selection thanks Matt Coady; read
changed the name of the &#8220;always_show_clear&#8221; property to &#8220;show_clear_date&#8221; and it now can be true, false or 0 (zero), instead o
changed the caption of the &#8220;clear date&#8221; button from &#8220;Clear&#8221; to &#8220;Clear date&#8221;;
minor optim
version 1.7.7 (May 26, 2013)
fixed a bug where setting the &#8220;direction&#8221; property was not working as expected when having the &#8220;format&#8221; set to just years or months and &#8220;direction&#8221; was set to an array of 2 like [] when &#8220;format&#8221; was set to &#8220;Y&#8221;; thanks Kai;
fixed a bug where sometimes the date picker was appearing too far to the right
thanks Mark;
version 1.7.5 (May 06, 2013)
additional fixes related to the buggy positioning of the date picker&#8217;s icon when the date picker in scenarios involving different CSS r
fixed a bug affecting some more rare thanks MSP
version 1.7.4 (May 05, 2013)
fixed a bug where the date picker was broken if the page was having the &#8220;box-sizing&#8221; CSS property set to &#8220;border-box&#8221;, which is the default for most of the CSS
fixed a few bugs related to the positioning of the icon when the date picker was used together with different CSS f
version 1.7.3 (May 03, 2013)
fixed a bug where having in the &#8220;disabled_dates&#8221; property a rule like [&#8216;* * * *&#8217;] (to disable all dates), and then, in the &#8220;enabled_dates&#8221; property having rules that enable only dates in the future, would send the script thanks Miguel Avila;
fixed a bug where if a default value did not have days, months and years but only fragments (like, &#8220;Feb&#8221; or &#8220;February&#8221; when format was set to &#8220;F&#8221; or &#8220;M&#8221; respectively) the current date was used as
thanks to MSP;
fixed a bug where, when searching for the first selectable date the library would sometimes fail and incorrectly show the month *after* the fi
fixed a bug that was introduced in the previous version that could break the script if ranges were used in the &#8220;disabled_dates&#8221; or &#8220;enabled_dates&#8221;
fixed an issue where if the only the &#8220;months&#8221; view was visible, the user could still use the &#8220;next&#8221; and &#8220;previous&#8221; but thanks MSP
version 1.7.1 (April 26, 2013)
fixed a bug where, when the &#8220;select_other_months&#8221; property was set to TRUE, days selected from outside the current
thanks MSP;
fixed an issue where the value of the &#8220;select_other_months&#8221; property was set to TRUE instead of FALSE
version 1.7.0 (April 22, 2013)
fixed an issue where after selecting a date, the focus would go to nowhere and you&#8217;d have to start tab-ing from now the focus goes to the element the date p
fixed an issue where when setting a format like &#8216;F&#8217;, &#8216;m&#8217;, &#8216;M&#8217; or &#8216;n&#8217; (so, months only), users ha thanks John;
fixed a bug where in IE7 &#038; 6 the &#8220;Clear&#8221; button was alternatively visible/invisible for each change of year/
added a new configuration option: &#8220;enabled_dates&#8221; which the reverse of the &#8220;disabled_dates&#8221; property, and which must be used together with the &#8220;disabled_dates&#8221; thanks to Sascha, Pranav Goswami and to all the others
the calendar icon is not absolutely positioned anymore, and thus fixing all the issues thanks to all the people who kept insisting ?
the &#8220;zero_pad&#8221; property is now FALSE
added 2 new configuration options: &#8220;show_other_months&#8221; which specified whether days belonging to other than the month being displayed should be shown, and &#8220;select_other_months&#8221; which specifies whether belonging to other than the month being displayed
thanks to Josh;
changed the &, & and & HTML entities to their numerical equivalents bacause they were apparently causing troubles in strict XHTML thanks Martin Luter;
optimized a bit the datepicker&#8217;s stylesheets (also changed their names, so watch out when you&#8217;re upgrading!); also, added a new styl
added in the documentation the fact that if month names are used with the &#8220;direction&#8221; property, these must be in English and not the values in the &#8220;months_abbr&#8221; thanks to Manfred;
the plugin is now available on !
version 1.6.7 (January 28, 2013)
fixed an issue due to which the plugin was not working with jQuery 1.9.0;
version 1.6.6 (January 15, 2013)
fixed a bug where the first selectable date was not computed if the &#8220;direction&#8221; property w thanks to Bastian Flinspach;
version 1.6.5 (January 12, 2013)
fixed an issue where, for paired date pickers, only a single date picker could be set using the &#8220;pair&#8221; now any number of date pickers can be set, thanks to Morten
version 1.6.4 (January 08, 2013)
fixed an error where using &#8220;D&#8221; in date&#8217;s format wo thanks James
version 1.6.3 (January 02, 2013)
fixed a bug where when using paired date pickers and the second date picker would not have the &#8220;direction&#8221; property set to something different than &#21;, the second date picker&#8217;s selectable dates would not get updated according to the values in t thanks to Martijn
fixed some bugs in the alternate CSS;
version 1.6.2 (December 13, 2012)
fixed a bug in example 7; thanks Morten
fixed a bug where the zero_pad configuration option was being applied only to the days of the current month and not also to the few, non-seletable, da thanks Morten
version 1.6.1 (November 03, 2012)
fixed a bug where using &#8220;M&#8221; (abbreviated month names) or &#8220;D&#8221; abbreviated day names in date format would result in the library returning the first three letters from months/days fullnames rather than the values given to the &#8220;months_abbr&#8221; and &#8220;days_abbr&#8221; thanks to mansoft;
added a new property: &#8220;show_icon&#8221; which when set to FALSE will disable the adding of the calendar icon to the elements the p thanks to maliang47;
the date picker&#8217;s position is now computed relative to the calendar icon&#8217;s top-right corner (instead of top-left corner as it was previously), unless the calendar icon is hidden when the position is calculated relative to the element&#8217;s top- so, remember to adjust the &#8220;offset&#8221; property when updating the plugin!;
the date picker will now open when clicking on the element the plugin is attached to regardless of the fact that the element thanks to Nicky;
version 1.6 (October 28, 2012)
fixed a bug where the algorithm for calculating the ISO 8601 week number was n thanks to Christian;
fixed a bug where if using the same starting and ending date for the &#8220;direction&#8221; configuration option, the date picker would behave as if there
thanks to Sachin;
fixed a bug where when the system was set to a time zone where daylight saving time would occur at midnight, selecting the particular date where the daylight saving time was applied would result in the plugin return thanks to Arvy!
a new &#8220;onClear&#8221; ev a function attached to this event will be executed wh thanks to Alan
added a new configuration option: &#8220;zero_pad&#8221;; setting it to FALSE will prevent the script from prefixing day numbers < 10 with zeroes (so, it will be "1" instead of "01"); thanks to Nicky
added 2 new configuration options: &#8220;days_abbr&#8221; and &#8220;months_abbrs&#8221; for specifying custom abbreviations for days and month names (useful for languages where the abbreviation is not as simple as the first 2 or 3 letters); thanks to RATI!;
the functions attached to the onSelect and onChange events will now receive an extra argument being a reference to the element the date picker is attached to, as a jQ
version 1.5 (September 30, 2012)
a new &#8220;onChange&#8221; event is now triggered whenever the user changes the view (days/months/years), as well as when the user navigates by clicking on the &#8220;next&#8221;/&#8221;previous&#8221; icons the callback function called by this event takes two arguments &#8211; the view (days/months/years) and the &#8220;active&#8221; elements (not disabled) in that view, as jQuery elements allowing for easy customization and interaction with particular cells in the date picker&#8217; read more about
thanks to Russell
fixed two bugs introduced in the previous version that made the icon to be incorrectly positioned in Internet Explorer 6, 7 &#038; 8 and also made the library trigger a warning messa
fixed a bug where setting the &#8220;disabled_dates&#8221; attribute to something else other than an array, would trigger an error in Internet Explorer 6 &#038; 7; thanks to myapi
version 1.4.2 (September 22, 2012)
fixed a bug where the icon would not be placed correctly if the element the plugin is att
fixed some small bugs in the CSS and in the JavaS
calling the &#8220;update&#8221; method will now also recalculate the parent element&#8217;s position and place
use it when you show/hide/reposition the parent element or you alter the parent element&#8217;
version 1.4.1 (July 29, 2012)
fixed a bug where, when two date pickers are paired, the second date picker&#8217;s starting date was using the first date picker&#8217;s date as starting date *only* after a date was selected in the first date picker and not also when the first date picker alread thanks to j-Walker
fixed an issue where the current system date was not highlighte thanks to Kevin Twitchell
the week number is now shown accord thanks to David Moros
version 1.4 (July 08, 2012)
fixed a bug where the date picker&#8217;s icon was not centered vertically relative t
added the possibility to select only years and
this behavior will be automatically triggered when setting an appropriate format &#8211; something like &#8220;Y-m&#8221; will allow users to select only years/months, while something like &#8220;Y&#8221; will allow users
if the element the plugin is attached to is disabled, the icon for opening the date picker will be greyed out and the user will not be able to
thanks Todd
all sorts of imaginable combinations regarding starting and ending dates can now be set &#8211; look for the &#8220;direction&#8221; property in the configuration options
two date picker&#8217;s can now be &#8220;paired&#8221; so that one date picker&#8217;s will use the value in the ot see the &#8220;pair&#8221;
a callback function can now be set to be executed when the look for the &#8220;onSelect&#8221; property in the configuration options
version 1.3.2 (April 20, 2012)
included a second stylesheet for users who don&#8217;t like the look thanks to daniel for r
fixed icon position when inside the element on O thanks Daniel;
fixed a bug introduced in the last version that made disabling dates using , (commas) and &#8211; (dashes) thanks Denis;
version 1.3.1 (April 07, 2012)
fixed a bug where, starting with jQuery 1.7, the plugin was not working properly in IE6 &#038; IE7; thanks to Warren Taylor;
fixed a bug where the &#8220;Clear&#8221; button broke the date picker&#8217;s layout in IE6 &#038; IE7; thanks to Warren Taylor;
version 1.3 (April 02, 2012)
added a new property called &#8220;start_date&#8221; that can be used to specify a default starting date for the date picker, without having to set this value as the default value in the field the date p thanks to Phill;
the date picker will now feature a button for clearing a prev this means that if the input the date picker is attached to is empty, and the user selects a date for the first time, this button once the user picked a date and opens the date picker again, this time the bu this button can be made permanently visible by setting the newly added &#8220;always_show_clear&#8221; property to TRUE; the caption of the button can be set through the newly added &#8220;lang_clear_date&#8221; thanks to Marc;
the date picker can now be kept visible all the time by setting the newly added &#8220;always_visible&#8221; property to a jQuery element that will act as the date picker&#8217; thanks to red for suggesting this, and to everybody else for insisting ?
fixed a bug where if the calendar icon didn&#8217;t have any parents with &#8220;position: relative&#8221;, it would appear at the
thanks to Primoz and nzn;
fixed a bug where pre-selected years and months were not highlighted if the date format didn&#8217;t have days, months and years, but was something particular like &#8220;Y-m&#8221; or just &#8220;Y&#8221;;
fixed a bug where January was never highlighted
version 1.2 (February 05, 2012)
the icon for opening the datepicker is now, by default, *inside* the parent element rath the old behaviour can still be achieved by setting the newly added &#8220;inside&#8221; property to FALSE;
fixed a bug where the default view, as defined in the settings, was correctly used subsequent clicks would open the datepicker in the &#8220;day picker&#8221; view, regardle
fixed a bug where the currently selected years and months were not highlight only the current system year and month were hi
fixed a bug where, if a range of selectable dates was given, users could still navigate to years/months outside the given range (although no dates could be selected from these years/months as they were disabled);
version 1.1.2 (September 11, 2011)
fixed a bug where unavailable months and years could also be clicked and thus sending the user to a month with
version 1.1.1 (August 29, 2011)
fixed a bug regarding event delegation that would crash the script
thanks to Sebi Popa for spotting it!
version 1.1 (August 24, 2011)
fixed a bug where trying to re-initialize the date picker would attach an extra calendar icon and an extra date p thanks to Murat
the &#8220;direction&#8221; property was enhanced and now can also be an array where the first value indicates the starting date and the direction of calendar, and the second value is the numbe thanks to FranckM
week numbers can now also be shown using the show_week_number property (thanks to Jorgen for suggesting);
if the readonly_element property is set to true (default), the date picker is also shown when the user cl thanks to Tomek
pressing the ESC key will now c
examples are now also available in the
version 1.0, bugfix (May 27, 2011)
a bug was fixed that prevented the script from using the date in the text box as default date
version 1.0 (May 26, 2011)
initial release
1114 responses to &#8220;Zebra_Datepicker, a lightweight datepicker jQuery plugin&#8221;
How to Convert In Hijri Zebra Calender?
Is zebara-datepicker support multi language? Example japanese version
Look into the configuration options &#8211; there you are able to set the month/day names and their abbreviations
how can i use it after ajax call
how to disable all dates coming after today dates
I have the &#8220;readonly_element&#8221; set to false, allowing users to type in dates.
What I want to happen is the datepicker to change when the user types in a valid date. For example, if they type &#/; then the datepicker will display this date. Is this possible? Thanks in advance.
Why my code doesnt work on the local?
Zebra_DatePicker examples
$(document).ready(function() {
$(&#8220;.datepicker&#8221;).Zebra_DatePicker({ format: &#8220;d-m-y&#8221; });
$(&#8220;#date1&#8221;).Zebra_DatePicker({
onSelect: function() {
$(this).change();
alert($(this).context.value);
orderly default css, jquery 3.0.0 min.js and zebradatepicker.js
Hi. How can I change date format dd-mm-yyyy. Also how can I disable past date from 01-01-2015? The date is showing 17-06-16 to me.
Hi Stefan.
I really am enjoying working with this great Zebra Datepicker.
My question is, how can I add this to dynamcally generated form inputs?
I wasn&#8217;t sure how to set up a listener in jquery, as the dynamic inputs load after the rest of the page.
Thanks for any help or resources.
hi, How can I make it work on iPad. Looks like once it is open, it can&#8217;t be closed on just touching the screen around it. How can I close the calendar on button click
Leave a Reply
copyright & 2006 - 2016 Stefan Gabos. all rights reserved.

我要回帖

更多关于 vs dialog 的文章

 

随机推荐