src/Ridvanbaluyos/Mmda/MMDA.php
final private function convertToTitle($string)
    {
        $string2 = [];
        $string = str_replace(['_', 'AVE.', 'BLVD.'], [' ', 'AVENUE', 'BOULEVARD'], $string);
        $words = explode(' ', $string);

        foreach ($words as $word) {
            if (!in_array($word, ['EDSA', 'U.N.'])) {
                $word = ucwords(mb_strtolower($word));
            }
            array_push($string2, $word);
        }

        return implode(' ', $string2);
    }
final private function convertToTitle($string)
    {
        $string2 = [];
        $string = str_replace(['_', 'AVE.', 'BLVD.'], [' ', 'AVENUE', 'BOULEVARD'], $string);
        $words = explode(' ', $string);

        foreach ($words as $word) {
            if (!in_array($word, ['EDSA', 'U.N.'])) {
                $word = ucwords(mb_strtolower($word));
            }
            array_push($string2, $word);
        }

        return implode(' ', $string2);
    }
final private function convertToTitle ( $ string ) { $ string2 = [ ] ; $ string = str_replace ( [ '_' , 'AVE.' , 'BLVD.' ] , [ ' ' , 'AVENUE' , 'BOULEVARD' ] , $ string ) ; $ words = explode ( ' ' , $ string ) ; foreach ( $ words as $ word ) { if ( ! in_array ( $ word , [ 'EDSA' , 'U.N.' ] ) ) { $ word = ucwords ( mb_strtolower ( $ word ) ) ; } array_push ( $ string2 , $ word ) ; } return implode ( ' ' , $ string2 ) ; }
This function sanitizes certain abbreviations into readable format.

@param $string
@return string
This function sanitizes certain abbreviations into readable format .