diff --git a/reference/strings/functions/sprintf.xml b/reference/strings/functions/sprintf.xml index 5515c19145..1845a50e55 100644 --- a/reference/strings/functions/sprintf.xml +++ b/reference/strings/functions/sprintf.xml @@ -1,5 +1,5 @@ - + @@ -87,6 +87,10 @@ d - the argument is treated as an integer, and presented as a (signed) decimal number. + + e - the argument is treated as scientific + notation (e.g. 1.2e+2). + u - the argument is treated as an integer, and presented as an unsigned decimal number. @@ -210,6 +214,18 @@ $money = $money1 + $money2; $formatted = sprintf("%01.2f", $money); // echo $formatted will output "123.10" ?> +]]> + + + + <function>sprintf</function>: scientific notation + + ]]>