Advertisement
Guest User

Untitled

a guest
May 24th, 2015
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.20 KB | None | 0 0
  1. function count_char($str='',$char=''){
  2. $count=0;
  3. if(function_exists('mb_substr_count')){
  4. $count=mb_substr_count($str,$char);
  5. }
  6. else{
  7. $count=substr_count($str,$char);
  8. }
  9. return $count;
  10. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement