We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

More format of Date

ejDatePicker how to add more format localization 
etc. Thai , Spain

best Regards


1 Reply

SN Sasikala Nagarajan Syncfusion Team August 22, 2014 12:37 PM UTC

 Hi Chatchai,

Thanks for using Syncfusion products.

We are having a property called "Locale" which accepts the string value and it is used to display the DatePicker with different culture format. If we want to use any cultures we have to add the script files of those corresponding culture in the sample. In order to add Spain Culture in the DatePicker we have to refer a Spain culture's s​cript file named "globalize.culture.es-ES.js".

 The below code depicts how to specify the culture in using "locale" property of the DatePicker control,​

 

$(function () {

        // declaration

        $("#Datepick").ejDatePicker({

            locale: "es-ES",

        });

 

    });

For your convenient, we have prepared a sample in DatePicker which uses Spain culture and it can be downloaded from the following location:

DatepickerinSpainsh

Globalize.js is a simple JavaScript library that allows you to format and parse numbers and dates in culture specific fashion. The globalize cultures is the open source and we can get all the cultures file from online, please refer the below online link,

 http://cdnjs.com/libraries/globalize/

 You can get the script file of various cultures from the following path also:

"<InstalledLocation>\Syncfusion\EssentialStudio\<version>\JavaScript\assets\external\culture"

 Please let us know if you need any further assistance.

Regards,

Sasikala Nagarajan


Loader.
Up arrow icon