Back to Form Builder Support

mike6629
mike6629

Can anyone help me add a date picker field type? Any recommendations or pointers would be greatly appreciated. Thanks!

Renatio
Renatio

Hi,

this is the basic workflow to do this:

  1. Go to website https://jqueryui.com/datepicker/
  2. Download jQuery UI (you can choose only datepicker)
  3. In your layout or page add jquery UI javascript library and CSS.
  4. In your main.js file:

    $(function() {
    
        $( ".datepicker" ).datepicker();
    
    });
  5. Just use default text type and add class datepicker.
  6. Add validation: https://laravel.com/docs/5.0/validation#rule-date

That's should do it.

Last updated

mike6629
mike6629

I'll give it a go. Thanks for the quick response!

jfo

1-4 of 4