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 / pradeep

Using sprinf("%04d",$num);

The above function will return a number of length 4.

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to remove blank spaces from the string?

973


Why and where do we use htaccess?

992


How do you identify independent and dependent variables in research?

874


What is string and its function?

934


Explain what is smarty?

1012


Can we set session value in javascript?

1000


What is the difference between explode () and split () functions in php?

1080


What are properties in php?

935


How can we determine whether a variable is set?

906


What is php7?

1021


How to get number of days between two given dates using PHP?

873


Why php is also called as scripting language?

920


What are the benefits of composer?

975


In how many ways we can retrieve the data in the result set of mysql using php?

902


How would you declare a function that receives one parameter name hello?

927