Answers for "php get only numbers"

PHP
1

php get only numbers

$str = 'In My Cart : 11 items';
$int = (int) filter_var($str, FILTER_SANITIZE_NUMBER_INT);
Posted by: Guest on November-24-2020

Browse Popular Code Answers by Language