我有一个按钮,我想按下按钮,它将成为在Timepicker插件中选择时间的显示面板。我可以通过按下文本框来实现,现在我想按下一个按钮。这是插件
http://trentrichardson.com/examples/timepicker/
这是我的代码:
<input type="text" placeholder="Set Time" id="S-Time"/><button>Click to show</button>
<script>
$('#S-Time').timepicker();
</script>
最佳答案
尝试这个:
$('#S-Time').timepicker();
$('button').click(function(){
$('#S-Time').focus();
});
关于jquery - 如何在Timepicker插件中单击按钮以显示时间?,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/17162404/