note 60818 deleted from function.intval by cmb

From: Date: Sun, 16 Feb 2020 13:52:47 +0000
Subject: note 60818 deleted from function.intval by cmb
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-214154@lists.php.net to get a copy of this message
Note Submitter: anonymous at place dot com ---- re: Disturbing issue with intval() It's probably just good practice to round decimals anyways. i.e... $amount = round(19.99 * 100); $test2 = intVal($amount); $test3 = intVal("$amount"); echo $test2 . "<br />\n"; echo $test3 . "<br />\n";

« previous php.notes (#214154) next »