I have a list of records with MySQL timestamps, the display of which works fine for my application.
Record 2 2009-06-09 09:33:39 Record 1 2009-06-02 11:33:33 etc... What I would like to do is make a little notification that says: "Record 2" was created in the previous 5 minutes! That's it, just a check of the first record. My first instinct is to check date.now versus the second representation of the timestamp but I can't see how to make that conversion that using the Date plugin, nor does there seem to be a trivial way to accomplish this. I know I can use the unix_timestamp() function in the MySQL calls but if there's 1000 records it seems a waste to use it for all records when I just need the first. Is there a better way to compare the timestamp to check if it's withing the last five minutes, or will I need to run unix_timestamp() on all queried records? Thanks! Tosh -- McIntosh Cooey - Twelve Hundred Group LLC - http://www.1200group.com/ _______________________________________________ templates mailing list [email protected] http://mail.template-toolkit.org/mailman/listinfo/templates
