Page 1 of 1

Calendar Events' listing (Months in French... possible?)

Posted: Thu 12. Nov 2009, 17:02
by StudioZ
Hi!
Using Oliver's original Calendar Module, I am looking for a way to have Months' names showing in french :roll:

Image

Question 01:
I have tried to change the "{STARTDATE:F}" all different ways but with no success :( .
What would be the tweak to have months showing in relation with "lang=fr"
Template:

Code: Select all

<div class="calendar">
	<div class="date">
		<div class="dateYear">{STARTDATE:Y}</div>
		<div class="dateMonth">{STARTDATE:F}</div>
		<div class="dateDay"><h1>{STARTDATE:d}</h1></div>
	</div>[TITLE]<h5>[HREF]<a href="{HREF}">[/HREF]{TITLE}[HREF]</a>[/HREF]</h5>[/TITLE]
        [PLACE]
	<p class="place">{PLACE}<br />[HREF]<a href="{HREF}">{STARTDATE:Y.m.d}</a>[/HREF]<br />Durée: {STARTDATE:H:i} - {ENDDATE:H:i}[TEXT]
	{TEXT}</p>[/TEXT][/PLACE]
</div>
I am calling the calendar with this code:

Code: Select all

{CALENDAR:
items=100
template=dates_list_fr.html
lang=fr
tag=novembre, décembre, janvier, november, december, january
tagmode=OR
date_start=01.01.2009
date_end=31.12.2010
href=index.php?calendrier
}
Question 02:
As I seen somewhere (can't remember in which thread) are these two lines supposed to be really in use:
date_start=01.01.2009
date_end=31.12.2010

Thanks in advance!

Yves

Re: Calendar Events' listing (Months in French... possible?)

Posted: Thu 12. Nov 2009, 22:05
by flip-flop
hi Yves,

1)

Code: Select all

{STARTDATE:l, j F Y lang=FR}
is the same like

Code: Select all

{STARTDATE:l, lang=FR} {STARTDATE:j lang=FR} {STARTDATE:F lang=FR} {STARTDATE:Y}
Result e.g.: Mercredi, 22 Avril 2009


2)
Since http://code.google.com/p/phpwcms/source/detail?r=348 we can use date_start and date_end

Knut

Re: Calendar Events' listing (Months in French... possible?)

Posted: Fri 13. Nov 2009, 07:56
by StudioZ
Yé! Your {STARTDATE:F lang=FR} is working perfect! :D
Always been of great help Knut :D 8)
I owe you another beer 8)

Salutations,

Yves

Re: Calendar Events' listing (Months in French... possible?)

Posted: Fri 13. Nov 2009, 08:26
by flip-flop
Santé Yves,

date_start/end makes it possible to make also dates visible from the past.
(Without this two parameters past dates are faded out).

Knut

Re: Calendar Events' listing (Months in French... possible?)

Posted: Fri 13. Nov 2009, 23:50
by StudioZ
flip-flop wrote:... date_start/end makes it possible to make also dates visible from the past.
(Without this two parameters past dates are faded out).
Knut
Hmmm... Just curious... :wink:

:?:
Knut, what would be the right syntax to use these parameters:
date_start=01.01.2009
date_end=31.12.2010
is it Year-Month-Day?
or is it Year/Month/Day?
I have a hard time figuring out this one :roll:
Every different combinations I tested has no effect on showing my past test events :roll:

Yves

Re: Calendar Events' listing (Months in French... possible?)

Posted: Sat 14. Nov 2009, 01:00
by flip-flop
I think you have´t switched to the new Calendar.class.
OG has changed to folder for this Calendar.class where date_start/end implemented.

frontend_render:

Code: Select all

if(strpos($content['all'], '{CALENDAR:')) {

// ===== my calendar css 
//	$GLOBALS['block']['css']['calendar'] = 'calendar.css'; // +kh: including the css file 

// ===== The old one
//	include(PHPWCMS_TEMPLATE.'inc_script/phpwcmsCalendar.class.php');  
// ===== The new since r348
	include('include/inc_module/mod_calendar/inc/phpwcmsCalendar.class.php');

		
	$myCal = & new phpwcmsCalendar();
	$myCal->parse($content['all']);

} 
Knut

Re: Calendar Events' listing (Months in French... possible?)

Posted: Sat 14. Nov 2009, 07:07
by StudioZ
Thank you for your help Knut! 8)

EDITED:
You helped me find out that in the latest distro R377 calendar.class.php:
/include/inc_module/mod_calendar/inc/calendar.class.php
needs to be unified for {IMAGE_CALENDAR}, and {TEXTLONG}
with file named phpwcmsCalendar.class.php:
/include/inc_module/mod_calendar/inc/phpwcmsCalendar.class.php

At least, I think we found the solution to nail down a couple issues. :)

Cheers,

Yves

Re: Calendar Events' listing (Months in French... possible?)

Posted: Sat 14. Nov 2009, 07:46
by StudioZ
Could not leave this one pass by... Sorry! :D :lol:
Frank Zappa wrote:And with that, GREGGERY turned and strode nonchalantly into his dinky little office with the desk and the catalog and the very hip water pipe, and proceeded, with a vigor and determination known only to piglets of a similarly diminutive proportion, to single-handedly invent THE CALENDAR!
-- From Album: Studio Tan — The Adventures Of Greggery Peccary, 20:35

Cheers, :wink:

Yves