Last active
December 17, 2015 16:09
-
-
Save bonny/5636690 to your computer and use it in GitHub Desktop.
simple_fields_register_field_group with date & timepicker 2 (for WordPress Simple Fields plugin)
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
<?php | |
simple_fields_register_field_group('date_field_group', | |
array ( | |
'name' => 'Test field group for date picker', | |
'fields' => array( | |
array( | |
'slug' => "my_date2_field_slug", | |
'name' => 'Test date selector', | |
'type' => 'date_v2', | |
"options" => array( | |
"show" => "on_click", | |
"show_as" => "datetime", | |
"default_date" => "today" | |
) | |
) | |
) | |
) | |
); | |
simple_fields_register_post_connector('test_connector_for_date', | |
array ( | |
'name' => "Connector for date", | |
'field_groups' => array( | |
array( | |
'slug' => 'date_field_group' | |
) | |
), | |
'post_types' => array('post', 'page', 'my_custom_post_type') | |
) | |
); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment