The Events Calendar
[resolved] How to disable datepicker "jump menu" behavior? (2 posts)

  1. BenHToronto
    Posted 2 years ago #

    Hi! The current implementation of the datepicker is not accessible, because it's a a jump menu (submits automatically on change of month or year). I'm fighting with the code to disable this behavior so I can simply add in a submit button.

    Any ideas on this? Thank you so much for your time!

    This comment in the-events-calendar/public/template-tags/calendar.php tips me off, but doesn't quite answer my question.

    * Month / Year Dropdown Selector (Display)
    * Display the year & month dropdowns. JavaScript in the resources/events-admin.js file will autosubmit on the change event.
    * @param string $prefix A prefix to add to the ID of the calendar elements. This allows you to reuse the calendar on the same page.
    * @since 2.0
    function tribe_month_year_dropdowns( $prefix = '' ) {
    global $wp_query;

    if ( isset ( $wp_query->query_vars['eventDate'] ) ) {
    $date = $wp_query->query_vars['eventDate'];
    } else {
    $date = date_i18n( TribeDateUtils::DBDATEFORMAT );
    $monthOptions = TribeEventsViewHelpers::getMonthOptions( $date );
    $yearOptions = TribeEventsViewHelpers::getYearOptions( $date );


  2. Barry
    Plugin Author

    Posted 2 years ago #

    We'd love to help further but technical assistance at this level isn't something we can provide here on the free support forum.

    Please do consider posting feature requests if you feel there ought to be a change in this regard in our future releases, though.


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • The Events Calendar
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic