1if(!function_exists('get_avatar')){
2 function get_avatar($str){
3 $acronym;
4 $word;
5 $words = preg_split("/(\s|\-|\.)/", $str);
6 foreach($words as $w) {
7 $acronym .= substr($w,0,1);
8 }
9 $word = $word . $acronym ;
10 return $word;
11 }
12}
13