Paula You could achieve this by calling the wpcf7_init
action hook provided by contact form 7.
You need to modify the functions.php
file and add the following codes at the bottom of your file.
add_action( 'wpcf7_init', 'custom_add_form_tag_time_selector' );
function custom_add_form_tag_time_selector() {
wpcf7_add_form_tag( 'time_selector', 'custom_time_selector_form_tag_handler' );
}
function custom_time_selector_form_tag_handler( $tag ) {
if( ! $tag instanceof WPCF7_FormTag ) return '';
$name = $tag->name;
if (empty($name)) {
$name = 'time_selector';
}
return '<input type="time" name="'.$name.'" value="" />';
}
I hope this will help you you.