[ic] time tag with adjust in February bug?

Paul Jordan paul at gishnetwork.com
Sun Mar 31 14:27:46 UTC 2013

Doing this today:

A)    [time]%c[/time] <br />
B) - 1d: [time adjust='-1 day']%c[/time] <br />
C) - 1m1d: [time adjust='-1 month 1 day']%c[/time] <br />
D) - 2m1d: [time  adjust='-2 month 1 day']%c[/time] <br />

gives me:

A)                Sun Mar 31 07:04:42 2013
B) - 1d:        Sat Mar 30 07:04:42 2013
C) - 1m1d:   Sat Mar 2 06:04:42 2013
D) - 2m1d:   Wed Jan 30 06:04:42 2013

Notice run C. Reaching past February seems to produce logical results, and I
have not noticed the system this code is running in producing oddities until
this, so think it has something to do with February specifically.

I guess it comes down to deciding what happens when minus one month and one
day is logically the same over a period of days. Would it be Feb 27th on
March 28, 29, 30, and 31?

What is adjust="- 1 month" doing? I would think it just reduces the month
field date-wise, and checks the if the day number exists in that result
month, and if not - use the last day number available for that result month.

Does that make presumptions not in line with the intentions of that

Paul Jordan

More information about the interchange-users mailing list