codehaven - php snippets - coding help
Generic filters
Exact matches only

Show Number as Decimal – Else show first number only

php codehaven

Depending if your number has a half like 1.5, 4.5 by checking if the last digit is a zero or not, then it will either show the full number with a decimal showing (1.5 and 4.5) or otherwise it will only show the first number, as it does not need an empty zero. It can […]