Hi.

I wanted to use Zend_Date to set day of the week and get Zend_Date object
which represents that date.

I looked in setDay(), but it was working for setting day of a month (1-31)
or setting a string representation of a day for given locale. Why I cant do
sth like Zend_Date->setDayOfWeek(3); // wednesday? Instead I need to mess
with strings and do setDay('Montag', 'de_AT')? Is there any easy way to
achieve this.

In order to achieve this I did a simple fix http://pastie.org/1332064

This works great for all days except sunday, If I do
$date->setDayOfWeek(Umpirsky_Date::DAY_SUNDAY) which is actually doing
$date->setDay('sun', 'en_GB'); I get sunday from last week string(20)
"28.11.2010. 12.16.27" and I'm expecting this week.

Why this happends and can I set when the week starts (on monday, on sunday)
or sth like that to get expected behaviour?

Regards,
Saša Stamenković.
-- 
View this message in context: 
http://zend-framework-community.634137.n4.nabble.com/Zend-Date-setDay-works-strange-for-sundays-tp3063414p3063414.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to