Jeff Tillotson wrote: > Greetings, > I have been searching for a way to do this and have not had any luck. > > I am using localtime() to determine the day of the month. I need to > make sure the variable it returns will always be 2 digits and padded > with zeros. For example currently it is like: > $var = (localtime)[3]; > $var would be 5. Then just sprintf it like:
$var = sprintf "%02d", (localtime)[3]; Using %02d tells sprintf to pad using 0. So 4 woulb e04 and 11 would be 11. Wags ;) ********************************************************** This message contains information that is confidential and proprietary to FedEx Freight or its affiliates. It is intended only for the recipient named and for the express purpose(s) described therein. Any other use is prohibited. **************************************************************** -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]