Help Desk

Adding text within the submission form

  • Posts: 12 Topics: 9
    | Permalink

    I’m finding that submitters are reluctant to add more than a few works within the Event Description field and would like to add something like “No less than 50 words are required” to that Event Description title (or beside it).
    Would you be able to point me in the right direction – i am not a coder!

    Thanks in advance.
    Colin

    Posts: 18146 Topics: 17 Answers: 973
    | Permalink

    Hi Colin,

    We’d be happy to point you in the right direction if we can. I appreciate your note that you aren’t a coder – realistically though it’s important to note that many changes like this one do involve working with code. That said, it shouldn’t be too tricky in this sort of case.

    Try adding a snippet like this one to your theme’s functions.php file (of course, adapt the message to suit):

    add_action( 'tribe_events_community_before_the_content', 'custom_ce_text_msg' );
    
    function custom_ce_text_msg() {
        echo 'Your submission must include at least 50 words - thanks!';
    }

    Does that work for you?

    Posts: 12 Topics: 9
    | Permalink

    Hi Barry, Thank you very much – that worked perfectly. On that logic I attempted to add text for the upload image. I adapted as suggested but something is incorrect. An chance of a pointer, please.

    add_action( ‘tribe_events_community_before_the_event_image’, ‘custom_ce_text_msg2’ );
    function custom_ce_text_msg2() {
    echo ‘A picture is worth a thousand words… Upload yours in landscape orientation, please!’;
    }

    Posts: 18146 Topics: 17 Answers: 973
    | Permalink

    Hi!

    Try changing the action from:

    tribe_events_community_before_the_event_image

    To:

    tribe_events_community_before_the_featured_image

    Does that help?

    Posts: 12 Topics: 9
    | Permalink

    Cheers Barry, that worked great

    Posts: 18146 Topics: 17 Answers: 973
    | Permalink

    Fantastic!

    I’ll go ahead and close this thread in that case – but if we can help with anything else please do create a new thread and one of the team will be only too happy to help 🙂

    (…and, if you have a moment, we’d love to hear your thoughts on The Events Calendar across on our plugin review page.)

    Thanks again!

The topic ‘Adding text within the submission form’ is closed to new replies.