3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $amount = '1,00'; $in_cents = (int) str_replace(',', '', $amount) * 100; echo $in_cents;
based on lutJd
Output for 4.3.0 - 7.2.0
10000