I want to count the number of a certian character (such as a pipe) in a string. For example:
$mystring = "me|you|otherguy"
$mystring_count = count($mystring,"|");
I know that's not right, but you get the idea...
thanks!
$array = explode ("|", $mystring); $count = count ($array) - 1;
http://php.net/manual/en/function.count-chars.php
assuming you have php4