How do I find the sum of all the digits in a number in PHP?
Another way, not so fast, not single line simple
It also assumes the number is positive.