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

Answer Posted / mahidhar

syntax:number_format("number","decimal places","string
seperator","string thousands seperator");

Example:number_format('1000',2,'.','')

Is This Answer Correct ?    6 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which cryptographic functions in php returns the longest hash value?

568


Name and explain five of the PHP error constants?

509


What is the difference between "echo" and "print" in php?

512


How can you propagate a session id?

525


Is php easier than node?

515






What is a base url?

501


What is the alternative structure for control structures?

580


How to get the total number of values in an array?

514


How can we submit from without a submit button?

570


What is the use of the function htmlentities?

617


What is null value in php?

563


Tell me what is the use of "enctype" attribute in a html form?

542


What are the advantages of stored procedures, triggers, indexes in php?

494


What is difference between post and put in rest?

507


Why does php start with variables?

539