On Sun, 12 Jan 2003, David Wheeler wrote:

> On Sunday, January 12, 2003, at 11:15  AM, John Peacock wrote:
>
> > A lot of the 0-based vs 1-based arguments should be resolved simply by
> > having our interface design in place.  Programmers will be less
> > inclined to have to look up some 0-based array when the API we provide
> > does it for them, i.e.
> >
> >     month[$date->month_num] vs. $date->month both return January
>
> I think that this will be resolved by:
>
> >  month[$date->month_0] vs. $date->month both return January

Make that:

 $month[ $date->month_0 ] vs. $date->month_name

$date->month returns a 1-based numbers
$date->month_0 a 0-based named
$date->month_name returns a name based on the DateTime::Language module
the $date object is holding onto.


-dave

/*=======================
House Absolute Consulting
www.houseabsolute.com
=======================*/

Reply via email to