Exemplo n.º 1
0
 /**
  * Method called for pre-parse processing.
  * @param	string	$text	The input text.
  * @return	string	The text that will be parsed.
  */
 public function onStart($text)
 {
     // process of smileys and other special characters
     if ($this->getParam('convertSmileys')) {
         $text = Smiley::convertSmileys($text);
     }
     if ($this->getParam('convertSymbols')) {
         $text = Smiley::convertSymbols($text);
     }
     // if a specific pre-parse function was defined, it is called
     $func = $this->getParam('preParseFunction');
     if (isset($func)) {
         $text = $func($text);
     }
     return $text;
 }