How to override datepicker configuration?

For pre-2.3 versions it is possible to do by using filter 'wccf_datepicker_config'. Here's the example how you can use it in your functions.php file:

add_filter('wccf_datepicker_config', 'change_datepicker_config');
function change_datepicker_config($config) { $new_config = array_merge($config, array( 'changeMonth' => true, 'changeYear' => true, )); return $new_config; }

You can read more here about possible configurations.

Starting from 2.3 version there were quite a few changes related to date picker - we added time picker, date/time picker as well as changed the actual JavaScript library from jQuery UI Datepicker to another library called Datetimepicker:

Because of that, old configuration and old filter hook wccf_datepicker_config will no longer work (as stated in release notes).

You can familiarise yourself with the new date/time picker configuration options in the page above and use the following filter hooks to change any aspect of date/time pickers on your site:

Here's the example of changing the minimal date:

add_filter('wccf_datetimepicker_datetime_config', 'wccf_datetimepicker_datetime_config_change');

function wccf_datetimepicker_datetime_config_change($config) {
$new_config = array_merge($config, array(
'minDate' => '+01/01/1970',

return $new_config;

Feel free to submit a support ticket to us if you have any questions.

Have more questions? Submit a request