View Full Version : About date display in Epoch calendar Help

03-27-2014, 08:22 PM
Hi there,
at the moment, I'm modifying/adding code on the Epoch calendar v.106 to use it on my website. And for that, I added a validating button that allows me to catch the date and put in in a form.

I succeeded in catching the date, but, though I changed the name of days and monthes, and changed the date format also(on line 802 of the 'epoch_classes.js' file), the displayed date (in an 'alert()' window for the test) is under the following form :

Thu Mar 20 2014 00:00:00 GMT+0100.

And what I want is something like, in french,

Jeudi 20 mars 2014, just that. Do you know how to do that ? Thanks,


03-28-2014, 05:30 AM
What you get in an alert() for a test might not be what you will see on the page when actually using the script.

If you want more help, please include a link to the page on your site that contains the problematic code so we can check it out.

Also, if you want French - you can download the French version (if you haven't already):


03-28-2014, 10:54 AM
Hi jscheuer1,
and thanks for your response. Actually, I've already transformed the calendar in a french one ^^. I'm going to catch the selected dates in the form i prepared for, and if the date format is still problematic after that, i'll do what you've said, i mean, send the part of the code i've modified. See you soon :)

03-28-2014, 03:24 PM
well, i finally finded out how to display the date in a french format by using toLocalDate(). But several points are still annoying me ; for example, when i have several dates selected, when i dispaly it with the following code :

validSelected.onclick = function() { alert(this.owner.selectedDates.toLocaleString());};

i tried to separate the results with a space using join(' ') just after toLocaleString(), but it doesn't work, what is surprising because, if i use split(), it properly works and adds commas after each word. Do you know what's happening. Thanks to all for your help,


03-29-2014, 05:27 AM
The result of the toLocaleString() method is a string. A string cannot be joined, it can be split though. Then it becomes an array, which if alerted or displayed is automatically type converted to a string with commas as the default delimiters being shown as a part of that string.