Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter mrjive

    (@mrjive)

    Actually, maybe it’s not an issue related to this plugin, but rather it is about how polylang manages the translation.
    It’s the same for menus: you have to create a menu for each language.

    But how can I have different event list widget for different languages?…

    🙂

    caimin_nwl

    (@caimin_nwl)

    Hi,

    Glad you’re enjoying the plugin.

    I think this needs to be something you’d ask the Polylang developers, I couldn’t see any reference on how to do this on the plugin page.

    Thread Starter mrjive

    (@mrjive)

    Hi, thanks for the reply.

    I tried to modify the plugin. I added “language” field in this file:

    events-manager/widgets/em-events.php

    adding the following at the end of the “function form($instance)”:

    <p><label for=”<?php echo $this->get_field_id(‘language’); ?>”><?php _e(‘Language’,’dbem’); ?>: </label>
    <input type=”text” name=”<?php echo $this->get_field_name(‘language’); ?>” value=”<?php echo (!empty($instance[‘language’])) ? $instance[‘language’]:__(‘Language’, ‘dbem’); ?>”></p>

    and it automatically filtered by language.

    I know it’s not well done at all, but for now it’s working. I’m not an expert coder, but I’ll try to make it better (like checking if polylang is installed, to give the option to ignore the language filed….) and maybe submit it to the team.

    ciao!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Event list widget displaying events in all languages’ is closed to new replies.