Lines Matching refs:text

63  * @param string $string  line of text
681 * returns true if the text contains any bad words
699 * @param string $text - optional text to check, if not given the globals are used
702 function checkwordblock($text = '') {
714 if(!$text) $text = "$PRE $TEXT $SUF $SUM";
716 // we prepare the text a tiny bit to prevent spammers circumventing URL checks
718 $text = preg_replace(
721 $text
746 if(count($re) && preg_match('#('.join('|', $re).')#si', $text, $matches)) {
1004 * also makes sure the given text is valid UTF-8
1009 * @param string $text
1012 function cleanText($text) {
1013 $text = preg_replace("/(\015\012)|(\015)/", "\012", $text);
1015 // if the text is not valid UTF-8 we simply assume latin1
1018 if(!\dokuwiki\Utf8\Clean::isUtf8($text)) $text = utf8_encode($text);
1020 return $text;
1024 * Prepares text for print in Webforms by encoding special chars.
1031 * @param string $text
1034 function formText($text) {
1035 $text = str_replace("\012", "\015\012", $text);
1036 return htmlspecialchars($text);
1040 * Returns the specified local text in raw format
1082 'tpl' => '', // the text used as template
1083 'tplfile' => '', // the file above text was/should be loaded from
1084 'doreplace' => true // should wildcard replacements be done on the text?
1131 * @var string $tpl the text used as template
1132 * @var string $tplfile the file above text was/should be loaded from
1133 * @var bool $doreplace should wildcard replacements be done on the text?
1215 $text = io_readWikiPage(wikiFN($id, $rev), $id, $rev);
1221 $to = !$to ? strlen($text) : ($to - 1);
1224 $slices[0] = substr($text, 0, $from);
1225 $slices[1] = substr($text, $from, $to - $from);
1226 $slices[2] = substr($text, $to);
1231 * Joins wiki text slices
1233 * function to join the text slices.
1240 * @param string $text text in the middle
1245 function con($pre, $text, $suf, $pretty = false) {
1248 substr($text, 0, 1) !== "\n"
1252 if($suf !== '' && substr($text, -1) !== "\n" &&
1255 $text .= "\n";
1259 return $pre.$text.$suf;
1320 * @param string $text wikitext being saved
1321 * @param string $summary summary of text update
1324 function saveWikiText($id, $text, $summary, $minor = false) {
1344 $svdta['newContent'] = $text;
1358 } else if(trim($text) == '') {
1752 * @param bool $textonly true returns only plain text, true allows returning html
1753 * @return string html or plain text(not escaped) of formatted user name
1765 * @param bool $textonly true returns only plain text, true allows returning html
1766 * @return string html or plain text(not escaped) of formatted user name
2005 * @param string $exc The text of the raised exception
2097 * Strips source mapping declarations from given text #601
2099 * @param string &$text reference to the CSS or JavaScript code to clean
2101 function stripsourcemaps(&$text){
2102 $text = preg_replace('/^(\/\/|\/\*)[@#]\s+sourceMappingURL=.*?(\*\/)?$/im', '\\1\\2', $text);