Hijri (Persian calendar) For DwtCalendar.js
Asked Answered
R

3

5

This is a DHTML Gregorian calendar widget. I'm trying to make an Hijri (Persian Calendar - Jalali) widget. Does anyone have any ideas?

Rumph answered 5/5, 2012 at 4:59 Comment(1)
@Micheal ! bad Edited ! sorry ! i means that how to convert DWTCalendar to a persian Calendar !Rumph
P
1

you can use this hijri calendar that support all jquery versions. i use these for persian Calendar.

amib Calendar and hasheminezhad Calendar

Prestigious answered 22/4, 2014 at 7:20 Comment(0)
S
5

Try this site, it contains JQuery calenders:

http://keith-wood.name/calendars.html

Note that this site contains a lot of calenders to choose from and one of them is the Persian calender.

Sagacious answered 5/5, 2012 at 5:24 Comment(6)
I means that how we can Convert DWTCalednar to persian (Hijri) Calendar!Rumph
oh! my apologies I'll check the code and then I will get back to you as soon as I can.Sagacious
It needs a lot of work to convert it to Hijri format, why not using a Hijri calender instead? Like the one I provided, it saves you time and I assume it will serve your purpose.Sagacious
Ok, DWTCalendar is using in Zimbra Collaboration Suite Web Client , i had to use DWT and i can't using any one.Rumph
I am afraid that you should develop on your own, I Googled this issue and I asked my colleague at work who has worked with Zimbra sometime ago, and he said there is no Hijri calender as he knows. EDIT Here are some articles I found that can help you with this kind of development, they are in C# but you can easily convert it to Javascript: codeproject.com/Articles/34192/HijriDateView-ASP-NET-Control codeproject.com/Articles/8838/… Good luck!Sagacious
look at this : https://github.com/farhadi/JalaliJSCalendar/tree/f5475f5c0bc0830c7d2ab8707708bf9e7d6ed0ba a complete Jalali Calendar(Persian) , is there any way to convert DWT to this ?Rumph
L
1

You want to change it for the Zimbra core or just to use it in a zimlet? If zimbra core, you need to be more familaiar with the structure of zimbra, its not just a file which needs to be translated but it has series of setting and few extra parts (look at the end of my comment for more tips!)

if you look at

http://files.zimbra.com/docs/zimlet/zcs/7.2.0/jsdocs/symbols/DwtCalendar.html

would notice that it doesn't have that much of relation with globalization

But if you want to have a zimlet that extends calender, you need to override calender view by overriding calender invoked functions in onShowMSG

It will need just a function to convert the calender to the persian one and mapping days

As you probably know the Persian calender conversation is just the matter of names and few mathematical calculation.

just add the calculations , set firstdayoftheweek and set names of days ....

you can find some usefull tips in Persian Calender implementation in Javascript

.

Some tips:

  1. Many of conifuration options are in \ajax\config\msgs\AjxMsg.properties\
  2. Its not dwtCalender that is important but mostly the other date related files like : AjxDateUtil.js in \ajax\util\
  3. Zimbra has the globalization abilities, try to look at zimbra for other languages to be familiar with the way they translate and places that should be change
Ludewig answered 19/9, 2012 at 11:32 Comment(0)
P
1

you can use this hijri calendar that support all jquery versions. i use these for persian Calendar.

amib Calendar and hasheminezhad Calendar

Prestigious answered 22/4, 2014 at 7:20 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.