note 123367 deleted from function.round by cmb
| From: | cmb@php.net | Date: | Wed, 12 Dec 2018 18:44:54 +0000 |
| Subject: | note 123367 deleted from function.round by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-209889@lists.php.net to get a copy of this message | ||
Note Submitter: Anonymous
----
PHP_ROUND_UP does not exist, but can be done by adding half of the decimal point value:
$CeiledValue = round(($ValueToRoundUp)+0.5*10 ** -$Decimal,$Decimal);
This basically does what ceil does for integers, but with decimal points.