PDA

View Full Version : How to count characters in variables?


amir103
02-16-2007, 07:13 PM
How can I count the number of characters (numbers in my case) in a variable and return the result as a variable itself. So that if $bob = 'cat' then $result = '3'.

angst
02-16-2007, 07:16 PM
strlen($string)