get the zero'ssssss

i have a numbers like this

#num = 0000001289

now, i want to remove zeros on it.
i tryd many code like this

$reference=number_format($num,6);
result = 001,289


$reference=number_format($num, 0, “0”, STR_PAD_LEFT);
result = 10289

what is want is like this -->>> 001289

any idea please… tnx :)

naaaaaaaaaaaaaaaa i got it i use

$reference=number_format($num, 0, ‘.’, ‘’);

but the result is like this = 1289 i think this one is ok
but if you have the code to result like this = 001289 just post it tnx… whew!

$reference=str_pad(intval($num),6,“0”,STR_PAD_LEFT);

:D :D tnx dude..... i will put you logo after i finish the program...
Sponsor our Newsletter | Privacy Policy | Terms of Service