[TYPO3] simple calendar time zone confusion

Katja Lampela katja.lampela at lieska.net
Wed Oct 3 08:07:08 CEST 2007


Wow - a bit late but maybe I will try this in next occasion. Because I 
really liked the simple calendar otherwise.

Thank you very much Giannis!

- Katja


Giannis Economou kirjoitti:
> Hello...
> 
> Just seen your post, and though you abandoned this, just an idea. We 
> have being using simple calendar with success regarding the timezone in 
> the past, but without the timezone fixes you described in your first post.
> 
> In order to fix the timezone problem, we have done the following:
> In main typo3 .htaccess (httpdocs/.htaccess), we have a line:
>    php_value auto_prepend_file '/var/www/httpdocs/php_tz.php'
> (where /var/www/httpdocs is the path to your document root)
> 
> and create the file /var/www/httpdocs/php_tz.php with content:
>    <?php
>    putenv ('TZ=Europe/Athens');
>    ?>
> where "TZ=Europe/Athens" is the timezone you are in.
> 
> Regards,
> Giannis
> 
> 
> Katja Lampela wrote:
>> Sad to say, I had to give up with this - so just for someone who 
>> hasn't too much knowledge of php, this wasn't a simple calendar for me 
>> after all; though very promising.
>>
>>
>> Katja Lampela kirjoitti:
>>  
>>> Okay I try to live with the fact that these two things I can't reach 
>>> simultaneously:
>>> 1. right time of the event record in FE (though all the time data in 
>>> BE looks alright)
>>> 2. the proper current date of the calendar.
>>>
>>> The main thing is ofcourse that the events show right time. Well, the 
>>> calendar then thinks it is tomorrow already. And this results in a 
>>> very much unwanted situation that today's events don't show at all 
>>> (not nice!)
>>>
>>> So what I try to do now is at least the following: I want to show in 
>>> the list view also "yesterday's" events which are in fact today's 
>>> events but the calendar thinks it is now tomorrow so they are 
>>> yesterday's events in calendar's twisted reason.
>>>
>>> But because of the lack of documentation I don't find where I could 
>>> (if I could) define what is displayed in list view; like "from 
>>> yesterday to the future".
>>>
>>> I found the options for the code for example: 
>>> list/c:1/l:3/o:1/r:1-1-2004,31-12-2004/d:5
>>> (category,location,organizer,month,year,range,daysahead)
>>> And d:-1 doesn't help of course.
>>>
>>> In the main class file there is at least this one place where the 
>>> date/time is handled:
>>> ------------------------------------------------------------------
>>>         // DATE MANIPULATIONS
>>>         $GDate = t3lib_div::GPvar('date');
>>>
>>>         if( isset( $GDate ) )   {
>>>             list($month,$year) = explode("-",$GDate);
>>>         }     else      {
>>>             $month = 
>>> ($this->selectParams['month'])?$this->selectParams['month']:date("m");
>>>             $year  = 
>>> ($this->selectParams['year'])?$this->selectParams['year']:date("Y");
>>>         }
>>>
>>>         $date_string = mktime(0,0,0,$month,1,$year);
>>>         $day_start = date("w",$date_string);  //The number of the 1st 
>>> day of the month
>>> ------------------------------------------------------------------
>>>
>>> but unfortunately I'm just starting my php learning and I don't 
>>> understand what i should do..
>>>
>>> So - any kind soul out there, please write me a hint, even if it was 
>>> just a vague idea..
>>>
>>> - katja
>>>
>>>
>>> Katja Lampela kirjoitti:
>>>    
>>>> Hello all,
>>>>
>>>> Another question aroused about the simple calendar. I get the event 
>>>> record's time shown right with this combination:
>>>>
>>>> - I put time zone (either the ext de_timezone record or the constant 
>>>> field plugin.tx_desimplecalendar_pi1.TZ) GMT -24
>>>> - time correction (plugin.tx_desimplecalendar_pi1.GMTcorrection) is 
>>>> activated
>>>>
>>>> This combination gives me also the unwanted situation: the calendar 
>>>> month view shows a wrong date for current date, one day ahead (in 
>>>> mon it shows it's already tuesday). And the monday events don't show 
>>>> because "it was yesterday" - in real it would be today.
>>>>
>>>> If I don't put the time zone and time correction as described, the 
>>>> event date is shown one day too early and also one hour too early.
>>>>
>>>> So, any ideas what I could do?
>>>>
>>>> - Katja
>>>>       
>> _______________________________________________
>> TYPO3-english mailing list
>> TYPO3-english at lists.netfielders.de
>> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>>
>>   
> 


More information about the TYPO3-english mailing list