I'd like to be able to print text that varies depending on whether the date matches a given date string
For example suppose there was a command
\iftoday#1#2#3
which printed #2 if \today matched the string in #1 and #3 otherwise.
So a sample of my proposed usage would be:
\iftoday{February 3, 2016}{There's no garbage today}{Please put out the garbage}
I've tried various commands like pdftexcmd's strcmp, to no avail.
I suspect the problem may have to do with matching the string generated by \today. While on screen it appears that \today returns February 3, 2016. I can't get it to match February 3, 2016 when I compare strings.
Obviously, I'd be perfectly happy if I could get this to work by represent today's date in any of the standard date formats.
Thanks very much in advance for any suggestions.


{}on the gui. – Feb 03 '16 at 06:58\todayis already fairly complex; fromtexdef:\today: macro:->\ifcase \month \or January\or February\or March\or April\or May\or June\or July\or August\or September\or October\or November\or December\fi \space \number \day , \number \year. You might have better luck withpgfcalendar's\pgfcalendarifdate{ date }{ tests }{ code }{ else code }. – jon Feb 03 '16 at 07:00