[opencms-dev] Calendar customization
    Hein van der Kallen 
    hvanderkallen at xs4all.nl
       
    Fri Nov 20 20:59:04 CET 2009
    
    
  
Fatemeh,
I asume you have the Calandar module working.
We converted it to Dutch ( on a Dutch only site) , but that is probably the same problem. 
We defined "nl" as a locale in opencms-system.xml but kept "en" as the first in <localesdefault>
( otherwise we would have to convert the rest of our site). 
We kept all content ( including the Calendar structured content ) in the default "en" locale. 
We adapted the calendar-nl.js in /system/workplace/resources/components/js_calendar/lang/
And made a display_nl_properties and a holydays_nl.properties in 
/system/modules/com.alkacon.opencms.calendar/classes/com/alkacon/opencms/calendar/
And to be sure copied them over the "en" ones an the ones without locale. 
Then in the start of different element jsp_files at the start we changed the locale to "nl" and at the and end to "en"
for instance in dailyoverview.jsp
<%@ page session="false" buffer="none" import="java.util.*, org.opencms.jsp.*, com.alkacon.opencms.calendar.*, org.opencms.util.*" %><%
CmsJspActionElement cms = new CmsJspActionElement(pageContext, request, response);
   cms.getRequestContext().setLocale(new Locale("nl"));
...
</div>
 <%  cms.getRequestContext().setLocale(new Locale("en")); %>
In the detail-entry.jsp an detail-serial.jsp we changed only the format-locale:
<fmt:setLocale value="nl" />
The rest of the work was not locale specific.
It is in production ( starting yesterday :-) ) on http://www.voorschoten97.nl/programma/Calendar/EvenementenKalender.html?&calView=1
Havank
. 
  ----- Original Message ----- 
  From: fatemeh.moradi 
  To: opencms-dev at opencms.org 
  Sent: Wednesday, November 18, 2009 8:54 AM
  Subject: [opencms-dev] Calendar customization
  Hi,
  I'd like to customize openCms calendar for Persian date so I added the calendar_fa.js to the path ../lang but only the names are customized but the date must be converted to Shamsi date too.how can i do it?
------------------------------------------------------------------------------
  _______________________________________________
  This mail is sent to you from the opencms-dev mailing list
  To change your list options, or to unsubscribe from the list, please visit
  http://lists.opencms.org/mailman/listinfo/opencms-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20091120/b49a8cf7/attachment.htm>
    
    
More information about the opencms-dev
mailing list