ctype_digit expects a string.

This function expects a string to be useful, so for example passing in
an integer may not return the expected result.