The problem described by skr should be pretty uncommon but if it  
happens to anyone it now suffices to rebuild the propel model.

Besides, if you want to use dates with no limitation in time (in  
particular dates before 1970) you should use the propel types BU_DATE  
and BU_TIMESTAMP, in which case the problem above will not occur either.

== Olivier

Le 18 déc. 06 à 17:52, chtito a écrit :

>
> I don't really understand... Could you print the output of
> $teilnehmer->getGeburtstag()? Where does that "12/05/69" format come
> from? Is that how the dates are stored in the database?
>
> Feel free to send me an email directly or to hang around on the
> #symfony irc channel tomorrow.
>
> == Olivier
>
> On 18 déc, 10:49, "skr" <[EMAIL PROTECTED]> wrote:
>> Did anybody had this problem too?
>>
>> in SF_ROOT_DIR/lib/symfony/i18n/sfDateFormat.class.php:
>> Impossible to parse date "12/05/69" with format "yyyy-MM-dd HH:mm:ss"
>>
>> My findings:
>> in _list_td_tabular.php  I got this line  :
>>       <td><?php echo ($teilnehmer->getGeburtstag() !== null &&
>> $teilnehmer->getGeburtstag() !== '') ?
>> format_date($teilnehmer->getGeburtstag(), "dd.MM.yyyy") : '' ?></td>
>>
>> If I use getGeburtstag(null), I get back a timestamp and everything
>> goes well again.
>>
>>       <td><?php echo ($teilnehmer->getGeburtstag() !== null &&
>> $teilnehmer->getGeburtstag() !== '') ?
>> format_date($teilnehmer->getGeburtstag(null), "dd.MM.yyyy") : ''
>> ?></td>
>>
>> The above line could be reduced, if the following patch is used:
>>
>> --- lib/symfony/i18n/sfDateFormat.class.php     (Revision 3078)
>> +++ lib/symfony/i18n/sfDateFormat.class.php     (Arbeitskopie)
>> @@ -118,6 +118,9 @@
>>    public function getDate($time, $pattern = null)
>>    {
>>      // if the type is not a php timestamp
>> +    if(is_null($time))
>> +      return null;
>> +
>>      if (is_string($time))
>>      {
>>        if (!$pattern)
>>
>> Ticket needed?
>
>
> >

--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"symfony developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/symfony-devs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to