#66. PHP String Length & Count Functions
How to work PHP String Length & Count Functions?
Run Code:
<?php
//$str = "Hello Sheikh";
$str = "Hello Sheikh Aqib. Hello Sqaib";
// strlen
//echo strlen($str);
// str_word_count
//echo str_word_count($str);
// str_word_count
//$array = str_word_count($str,2);
echo substr_count($str, "Hello", 5,21);
// echo "<pre>";
// print_r($array);
// echo "</pre>";
?>

Comments
Post a Comment