Question: I have a stored template, colours_daysbetween(), formatted as
colours_daysbetween($#lastread, '#00aaff', '#69cfff', '#9bdeff').
Code:
program:
arguments(date, colourA, colourB, colourC);
now = format_date(today(), 'yyyy-MM-dd');
if days_between(now,date) <#1 then colourA
elif days_between(now,date) <=# 14 then colourB
elif days_between(now,date) <=# 30 then colourC
fi
I don't remember where I got this (I possibly wrote it myself) but is there any particular reason to use a format_date() instead of just 'today()'? The template works when tested with the latter.