如何创建jQuery UI的日期选择器当前的月份和日期和年份只显示如何创建jQuery UI的日期选择器当前的月份和日期和年份只显示
<html>
<head>
<link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
<link rel="stylesheet" href="/resources/demos/style.css">
<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
<script>
$(function()
{
$("#datepicker").datepicker({
changeMonth: false,
changeYear: false,
});
});
</script>
</head>
<body>
<div class="row">
<label for="email">Check Date:</label><br />
<input id="datepicker" class="input" name="date" type="text" value="" required/><br />
</div>
</body>
</html>
告诉我如何禁用一切,只启用电流日期时间和年份
你是什么意思“当前月份和日期和年份只显示”? – Dekel
为什么然后能够选择,如果您禁用更改日期和年份的能力,并且在您的示例中,您也禁用了月份。 – Steve
我的意思是我在窗体中显示,但我想用户不能更改日期或月或年只在日历当前日期显示和其他禁用只是检查此代码,你会明白,我想说什么 –