Example #1
0
 public static function typo($text)
 {
     if (empty($text)) {
         return '';
     }
     $Typo = new self();
     $Typo->text = $text;
     $b = strpos($Typo->text, '<');
     $e = strpos($Typo->text, '>');
     if ($b !== false && $e !== false) {
         $Typo->_isHTMLCode = true;
     } else {
         $Typo->_isHTMLCode = false;
     }
     if ($Typo->doReplaceBefore) {
         $Typo->replaceBefore();
     }
     $Typo->spaces();
     $Typo->quotes();
     $Typo->dashes();
     $Typo->pbr();
     $Typo->replaceWindowsCodes();
     if ($Typo->doReplaceAfter) {
         $Typo->replaceAfter();
     }
     return $Typo->text;
 }