Hello everyone. I'm writing a perl script to implement some active content on my website. Does anyone know if there is a source code library to convert an integer variable to an equivalent character string? I've managed to do the reverse, i.e.
where $data and $hit_count are the character and integer variables respectively. The int_2_char job is proving a bit harder. Any help would be appriciated. Thanks.
perl will drop leading zeros in numbers, but you can stringify numbers to retain the leading zeros or use sprintf() or printf() to pad numbers with leading zeros.
perl will almost always know when to treat digitis as numbers or strings.
Thanks for the advice. I guess this means I wasted my effort with that little subroutine. However, at least you know for sure whats going to happen when you implement the conversion yourself.
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.