仅显示月份和日期年 jQuery Datepick 插件

发布于 2025-01-05 22:11:03 字数 193 浏览 3 评论 0原文

你好,我一直在使用 Keith Wood 的 Datepick jQuery 插件。但我想要的只是在选择上显示月份和年份。我知道这里已经有修复,但它是针对 jQuery Datepicker 的。

谢谢 :)

Hello I've been using Keith Wood's Datepick jQuery plugin. But what I want is only to show the month and year on the selection. I know that there is fix already here but it's for jQuery Datepicker.

Thanks :)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

梦在深巷 2025-01-12 22:11:03

你可以使用

 $('#birthdate').datepicker({
dateFormat: 'mm/yy',
changeMonth:true,
changeYear:true
});

you can use

 $('#birthdate').datepicker({
dateFormat: 'mm/yy',
changeMonth:true,
changeYear:true
});
Bonjour°[大白 2025-01-12 22:11:03

这是为了以后参考。这个就做到了。感谢那些帮助过的人

$('.dateNew').datepick({ 
           dateFormat: 'yy-mm', 
           altField: '.dateNew', 
           altFormat: 'mm-yy', 
           yearRange: '1930:2011', 
           changeMonth:true, changeYear:true  
    });

This is for future reference. This one did it. Thanks for those who helped

$('.dateNew').datepick({ 
           dateFormat: 'yy-mm', 
           altField: '.dateNew', 
           altFormat: 'mm-yy', 
           yearRange: '1930:2011', 
           changeMonth:true, changeYear:true  
    });
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文