Topic: PickaDate Methods
Igor Matveev pro asked 7 years ago
..html..
<input type="text" name="date">
<button class='btn btn-success'>Add date</button>
..js..
var i = $('input[name="date"]');
i.pickadate({ ..options.. });
$('.btn').click(function(){
i.pickadate('show'); // as in jQuery .datepicker( "show" );
//i.click(); // do not show pickadate
//i.focus(); // do not show pickadate
});
Can eat other ways?
Thanks!
Jakub Strebeyko staff answered 7 years ago
datePicker
on a button click is because it's self-contained, meaning the element holding the .datepicker
class is responsible for both triggering the rendering process and taking in the selected date data, and so it just must be an input. Setting these two apart would require heavy manipulation of datePicker
's code.
With Best Regards,
Kuba Igor Matveev pro commented 7 years ago
Thanks for answer. I hope in the next versions of MBD the functionality will be replenished with such delicious methods :)Jakub Strebeyko staff commented 7 years ago
Thanks, we'll definitely consider it.Closed
This topic is closed.
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Closed
- User: Pro
- Premium support: No
- Technology: MDB jQuery
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: No
- Provided link: No