arrays - How to correct my php number_format error? -


I get the error below my array code How can I fix this error to display results?

Error:

Warning: the value of the number-format () is 1 parameter double, string is

My code:

  $ account ['test'] = 775.57; $ Account ['savings'] = 2275.31; $ Account ['moneyMarket'] = 4554.43; Print ("& lt; Table & gt;"); Print ("& lt; tr & gt; & lt; td & gt; Checking Balance: & lt; / td> & lt; td & gt; $" Number-Detection (Check, 2). "& Lt ; / Td> & lt; / tr & gt; "); Print ("& lt; tr & gt; & lt; td & gt; Savings Balance: & lt; / td & gt; & lt; td & gt; $" No.-Format (saving, 2). "& Lt ; / Td> & lt; / tr & gt; "); Print ("& lt; tr & gt; & lt; td & gt; Money MkT Balance: & lt; / td & gt; & lt; td & gt; $" No.-Format (Money Market, 2). " & Lt; / td> & lt; / tr & gt; "); Print ("& lt; / Table & gt;");    

You must use $ to use the variable ...

  number_format ($ account ['checking'], 2)   

Otherwise, you are checking for constants that do not exist.

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -