Created
June 16, 2015 23:19
-
-
Save WillBrubaker/16aed85339534dc98bad to your computer and use it in GitHub Desktop.
Force Resource Selection for WooCommerce Bookings Resources
This file contains hidden or 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
add_filter( 'booking_form_fields', 'handsomebeardedguy_booking_form_fields' ); | |
function handsomebeardedguy_booking_form_fields( $fields ) { | |
if ( isset( $fields['wc_bookings_field_resource'] ) ) { | |
$fields['wc_bookings_field_resource']['options'][0] = 'Make a selection...'; | |
ksort( $fields['wc_bookings_field_resource']['options'] ); | |
} | |
return $fields; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment