php convert floating point string to int code example Example: php float to int $int = intval($float);