Home › Forums › Calendar Products › Community Events › Is it possible to make Community Event Image be Required?
- This topic has 4 replies, 4 voices, and was last updated 7 years, 1 month ago by Joanne.
-
AuthorPosts
-
February 14, 2017 at 2:10 pm #1234807JoanneParticipant
Is there a way to require an image be upload for a community event submission?
http://www.kidtivity.com/family-events-in-ct/community/add
Thanks!
February 14, 2017 at 4:49 pm #1234886GeorgeParticipantHey Joanne,
Thanks for reaching out!
This is unfortunately not possible “out of the box”, but may be possible with some custom coding.
Another customer actually just asked about this, and so I am working on a custom code solution. I may not be able to do it, and it may take me some time to do so, but sit tight — I will post an update here with news about my custom code solution to make featured images required for community events.
Stay tuned! 😀
GeorgeFebruary 16, 2017 at 9:28 am #1238843GeorgeParticipantHello!
I was able to produce a snippet that makes the featured image required for submitting a Community Event. That snippet is this:
add_filter( 'tribe_events_community_required_fields', 'tribe_community_require_image_to_submit', 10, 1 );function tribe_community_require_image_to_submit( $fields ) {
if ( ! is_array( $fields ) ) {
return $fields;
}$fields[] = 'EventImage';
return $fields;
}
☝️ Try adding this to your theme’s functions.php file and it should make featured images required.
You will have to take the reins on further refinement of this and/or other customizations, but I hope this helps! 😀
— George
March 10, 2017 at 8:35 am #1252399Support DroidKeymasterHey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.
Thanks so much!
The Events Calendar Support Team -
AuthorPosts
- The topic ‘Is it possible to make Community Event Image be Required?’ is closed to new replies.