How to show only one search option

Home Forums Calendar Products Event Aggregator How to show only one search option

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1423416
    Ryan Clover-Owens
    Participant

    All our events are on the same day, but all over the country.

    So our visitors will be searching via city or zip code. I love the search bar under the map by the way.

    Is it possible to remove the other search options, keyword and date?

    If so, how, and if it’s complicated, how would I describe the task to a developer who could help me?

    Thanks!
    Ryan

    #1424371
    Jennifer
    Keymaster

    Hi Ryan,

    I’m glad to hear that you’re liking the plugin so far! You can remove certain elements of the bar (like the keyword and date search boxes) by adding the snippets in this article. Specifically, you’ll want the following, which you can add to the functions.php file of your child theme:

    add_filter( 'tribe-events-bar-filters', 'remove_search_from_bar', 1000, 1 );
    function remove_search_from_bar( $filters ) {
    if ( isset( $filters['tribe-bar-date'] ) ) {
    unset( $filters['tribe-bar-date'] );
    }
    if ( isset( $filters['tribe-bar-search'] ) ) {
    unset( $filters['tribe-bar-search'] );
    }
    return $filters;
    }

    Can you give this a try and see if it works for you? Let me know how it goes!

    Thanks,

    Jennifer

    #1442614
    Support Droid
    Keymaster

    Hey 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

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘How to show only one search option’ is closed to new replies.