Last active
November 24, 2017 20:51
-
-
Save nefeline/aceabe1f914a0583340396d25c0b2308 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* This snippet changes the default start and end times for both The Events Calendar and Community Events. | |
*/ | |
function new_default_time( $default, $type ) { | |
if ( 'start' === $type ) { | |
return '09:00'; | |
} elseif ( 'end' === $type ) { | |
return '22:00'; | |
} | |
return $default; | |
} | |
add_action( 'tribe_events_meta_box_timepicker_default', 'new_default_time', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment