Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How do you format and output a number with leading zero's?

Answer Posted / mahesh

$d=450;
$d = str_pad($d,6,0,0);
echo $d;
OUT PUT
000450

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which function is used in php to check the data type of any variable?

912


What is the use of rand() in php?

1012


Where is my php ini file?

1033


What is meant by urlencode and urldecode?

1060


How to get the length of string?

990


Write a query to find the 2nd highest salary of an employee from the employee table?

1007


What is the sign to start variables in PHP?

1046


Is php a float?

975


What is the purpose of $_ session?

933


How do you check if a variable has not been set in php?

890


Explain what are the three classes of errors that can occur in php?

946


Is php object oriented?

892


Why is node js better than php?

1087


What does nan stand for computer science?

940


What the difference between the 'bitwise and' operator and the 'logical and' operator?

929