Sorry, copy-paste error, mysql format is
YYYY-MM-DD<http://dev.mysql.com/doc/refman/5.1/en/datetime.html>
.
*Can you please tall what is the problem with my view helper, and why there
are no date view helper and date filter in zf already?*
*
*
*Can you give an example on how to achieve this, date filtering and
formatting?*
*
*
*Thanks for the answer.*

Regards,
Saša Stamenković


On Mon, Dec 7, 2009 at 1:30 PM, Thomas Weidner <[email protected]>wrote:

> ----- Original Message ----- From: "umpirsky" <[email protected]>
> To: <[email protected]>
>
> Sent: Monday, December 07, 2009 11:19 AM
> Subject: [fw-general] Working with dates (filter, view helper)
>
>
>
>
>> Hi.
>>
>> I'm working with dates, date format in my database is standard mysql date
>> type (YYY-MM-DD).
>>
>> I want view helper to format my dates according to my locale settings,
>> which
>> are registered in registry under Zend_Locale key.
>>
>> Is this the right way to go http://pastie.org/731564 ?
>>
>
> Problematic code. I expect that you have severe problems when the
> input/date differs. Also the date format you gave is not the standard mysql
> date.
>
> I never saw a database having 3 digits of ISO year.
> Nor that it used 2 digits day of year.
>
>  I also want a filter to receive dates in Serbian date format (or any other
>> later from locale) and convert them to database ready format (YYY-MM-DD),
>> I've tried with http://pastie.org/731574 , but with no luck.
>>
>
> Wrong way... Zend_Locale does not produce dates.
> When you want to format a date then you must use Zend_Date.
>
>
>> Please help?
>> --
>> View this message in context:
>> http://n4.nabble.com/Working-with-dates-filter-view-helper-tp954267p954267.html
>> Sent from the Zend Framework mailing list archive at Nabble.com.
>>
>
>

Reply via email to