Is there an easy way to change an integer to a 5 caracters string. For example: $i = 3 ; $j = 110 ; After having changed them: $i = "00003" ; $j = "00110" ;
Is there a php function to do so instead of doing this:
if( ($i>0)&&($i<10)) {
$i = "0000".$i ;
} else if( ($i>9)&&($i<100)) {
$i = "000".$i ;
} else if( ($i>99)&&($i<1000)) {
$i = "00".$i ;
} etc...Thanks :-)
Vincent.
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

