At 15:33 24.06.2001 -0500, Tim Grossner wrote:
>I want to open a file:
>
>open (CONFIG, ">/tftpboot/$_");
>chmod (0777, "/tftpboot/$_");
>
>but i want to make the filename be $_."the current date"
>
>the localtime function doesnt look very promising, as the output is not
>very human readable :-)
>
>Any thoughts?

I actually prefer to keep the time format in the number format returned by 
time(), until I need to render it human readable -- especially for things 
like file names.  Numbers are typically safer to hand around than strings, 
and a file name composed of numbers is always guaranteed to be legal, while 
a string may contain characters that aren't allowed in file names by the 
operating system.
Aaron Craig
Programming
iSoftitler.com

Reply via email to