Lines Matching defs:text
25 * The added text replaces previous words for the same page.
29 * @param string $text the body of the page
35 public function addPageWords($page, $text)
49 $words = $this->getPageWords($text);
105 * @param string $text content of the page
112 protected function getPageWords($text)
115 $tokens = $this->tokenizer($text);
490 * Split the text into words for fulltext search
495 * This event allows plugins to modify the text before it gets tokenized.
498 * @param string $text plain text
500 * @return array list of words in the text
505 public function tokenizer($text, $wc = false)
510 // prepare the text to be tokenized
511 $evt = new Event('INDEXER_TEXT_PREPARE', $text);
513 if (preg_match('/[^0-9A-Za-z ]/u', $text)) {
514 $text = Asian::separateAsianWords($text);
520 $text = strtr(
521 $text,
524 if (preg_match('/[^0-9A-Za-z ]/u', $text))
525 $text = Clean::stripspecials($text, ' ', '\._\-:' . $wc);
527 $wordlist = explode(' ', $text);