PHP string functions question
Posted: Wed Jun 20, 2007 2:50 pm
How would I get PHP to read the only the last digit of a number?
I want to insert a number, have PHP read the last digit of it, and then take a specific action depending on that last digit. I looked through the string functions list on php.net but had no luck finding what I was looking for.
If anyone knows the function I'm trying to find, please post it. I appreciate all your help.
I want to insert a number, have PHP read the last digit of it, and then take a specific action depending on that last digit. I looked through the string functions list on php.net but had no luck finding what I was looking for.
If anyone knows the function I'm trying to find, please post it. I appreciate all your help.