Page 1 of 1

How to translate dates in CMSMS? News, Calendar etc.

Posted: Mon Sep 06, 2010 9:28 pm
by mjrumble
Hi, Does anybody know how to go about changing the date lang in cmsms. I am trying to do it under CGCalendar I have made a translation for everything but the months will not change. I have made searches through the whole files in my site but only a java script shows the months. Changing these does not change anything. Anybody got any ideas? Does it come from the server?

The same goes for news. Has anybody had luck with this?

Thanks in advance.

Re: How to translate dates in CMSMS? News, Calendar etc.

Posted: Tue Sep 07, 2010 1:24 pm
by owr_bgld

Re: How to translate dates in CMSMS? News, Calendar etc.

Posted: Tue Sep 07, 2010 7:54 pm
by mjrumble
Thanks for the reply,

I should have said I want to change the lang to Welsh which as far I know not supported but a server. I have made Welsh a new lang in cmsms and happy with changing date format but i want to define my own name for the days and months. Any ideas?

thanks

Re: How to translate dates in CMSMS? News, Calendar etc.

Posted: Tue Sep 07, 2010 9:15 pm
by owr_bgld
So on the fly - maybe with an udt

first make an UDT

Code: Select all

if ($month == "January" || $month =="01") {$welshmonth = "welshmonthnameJan";}
elseif ($month == "February" || $month =="02") {$welshmonth = "welshmonthnameFeb";}
........
elseif ($month == "December" || $month =="12") {$welshmonth = "welshmonthnameDec";}
echo $welshmonth;
you have to change the template with the right Names of themonths

second: you can put an UDT to the template (example from CGCalendar-Template)
instead of

Code: Select all

{$month_names[$month]}
{Name_of_UDT month="$month_names[$month]"}

Re: How to translate dates in CMSMS? News, Calendar etc.

Posted: Fri Dec 03, 2010 3:55 pm
by Hypocrite
How does this work for the search form template?

It has this code to generate the dropdown lists:

Code: Select all

{capture assign='tmp'}{$actionid}cal_search_end_date_{/capture}
{html_select_date prefix=$tmp time=$search_end_date start_year=-1 end_year=+2}
{* {html_select_time prefix=$tmp time=$search_end_date display_seconds=0} *}
And they all in English even though I have translated them.