substr_count

Example

 int substr_count ( string $haystack , string $needle [, int $offset = 0 [, int $length ]] ) 

Description

substr_count() returns the number of times the needle substring occurs in the haystack string. Please note that needle is case sensitive. Note: This function doesn't count overlapped substrings. See the example below!

Return Values

This function returns an integer.