Calendar widget "next month problem"
-
My site is in two languages: En and Ru (using wpml). When displaying mini calendar widget the calendar translations are fine up to when cliking on “>>” or “<<” to change month. The widget loads next month and translation is gone (calendar is displayed in default language, ie English). Any fix?
-
Hi,
I tried this one and seems to be working fine; are you using Events Manager and WPML Compatibility plugin?
if you are having some problem with this plugin – http://ww.wp.xz.cn/support/topic/em-wpml-warning-call_user_func_array-functioncall-user-func-array?replies=12also, do you have a sample link?
Hi
Thanks for the reply agelonwl. The site is here: http://tinyurl.com/ary9tvw – try to change the month and you will see what I mean.
Hi,
can I know if you have tried to define or add new wordpress localization at wp-content/languages? e.g. http://codex.ww.wp.xz.cn/Translating_WordPress
or click ‘Review Changes and update’ then at the bottom of that page click ‘update’ (WPML > Theme and plugins localization > Language locale settings)
did you try with this plugin – http://ww.wp.xz.cn/extend/plugins/events-manager-wpml/
I have http://ww.wp.xz.cn/extend/plugins/events-manager-wpml/ 0.1 installed on live site. Just installed 0.2 on my local wamp server to try it but still having the same problem.
(Event Manager version is 5.3.5)
Does anybody else have this problem or only me? It seems that the widget “forgets” the language parameter as soon as you click on next or previous month and this problem should affect all multilingual sites that use this plugin…
I tried this out in Spanish and it works for me. I replied to you here too – http://ww.wp.xz.cn/support/topic/mini-calendar-widget-translation?replies=3
Hi Marcus, thanks for replying and thanks for this wonderful plugin.
Did you have time to check my site http://tinyurl.com/ary9tvw and see the problem there? I have all translations and it works great just up until you press next or previous month in the mini calendar…
I don’t think this problem is my site or theme related, just tried with another one and it was the same case.
did you get this working? the calendar looks translated to me when switching months.
I didn’t. Did you try only in English? Please try in Russian: http://tinyurl.com/aha88nf For me the problem is that my default language is Estonian and when switching months in English or Russian the Estonian translation comes up.
Would it help if wpml language parameter could be included here:
`//Get an array of arguments that don’t include default valued args
$link_args = self::get_link_args($args);$previous_url = “?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&{$link_args}”;
$next_url = “?ajaxCalendar=1&mo={$month_next}&yr={$year_next}&{$link_args}”;`So it would be something like:
"?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&{$link_args}&lang=En / Ru / Et...""?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&{$link_args}&lang=ru"actually works! So the problem would be solved if universal language parameter (instead of specific language ie “ru” would be included. What is that in wpml php code?btw, I am changing the em-calendar.php file.
Solved!
used this code as a workaround
`$previous_url = “?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&{$link_args}”;
$next_url = “?ajaxCalendar=1&mo={$month_next}&yr={$year_next}&{$link_args}”;if (ICL_LANGUAGE_CODE == ‘ru’) {
$previous_url = “?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&lang=ru&{$link_args}”;
$next_url = “?ajaxCalendar=1&mo={$month_next}&yr={$year_next}&lang=ru&{$link_args}”;
} elseif (ICL_LANGUAGE_CODE == ‘en’) {
$previous_url = “?ajaxCalendar=1&mo={$month_last}&yr={$year_last}&lang=en&{$link_args}”;
$next_url = “?ajaxCalendar=1&mo={$month_next}&yr={$year_next}&lang=en&{$link_args}”;
}`Thanks systemo13 !!!
For qtranslate plugin: qtrans_getLanguage() instead ICL_LANGUAGE_CODE
The topic ‘Calendar widget "next month problem"’ is closed to new replies.