Calendario - How to custom locale render text?

1 reply · opened Jul 1, 2023

MmynameismrbinhJul 1, 2023

Hi Team,

Calendario's does not talk about locale text (by country).
Please help me how to custom it ?
Specifically, I want to set something like:
`jQuery( '#calendar' ).calendario({
onDayClick: ...,
caldata : ...,
locale: "vietnamese", // I want this

});`

Thanks

SSemicolon WebSTAFFJul 1, 2023

Hello,

This is definitely possible but you will need to manually setup the Texts of the Calendar in your Language. Consider using the code below:
[ch_pre type="js"]jQuery( '#calendar' ).calendario({
weeks : ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],
weekabbrs : ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
months : ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],
monthabbrs : ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
onDayClick : function( $el, $contentEl, dateProperties ) {

	for( var key in dateProperties ) {
		console.log( key + ' = ' + dateProperties[ key ] );
	}

},
caldata : canvasEvents
...

});[/ch_pre]

And convert the Texts in Vietnamese as required.

Hope this Helps!

Let us know if we can help you with anything else or if you find any further issues.

Have the same question, or something new?

Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.

Reply on the dashboard