protected function MarkdownExtra::doAbbreviations in Markdown 7
* Find defined abbreviations in text and wrap them in <abbr> elements. *
Parameters
string $text: * @return string
File
- includes/
MarkdownExtra.php, line 1752
Class
- MarkdownExtra
- Markdown Extra Parser Class
Namespace
MichelfCode
protected function doAbbreviations($text) {
if ($this->abbr_word_re) {
// cannot use the /x modifier because abbr_word_re may
// contain significant spaces:
$text = preg_replace_callback('{' . '(?<![\\w\\x1A])' . '(?:' . $this->abbr_word_re . ')' . '(?![\\w\\x1A])' . '}', array(
$this,
'_doAbbreviations_callback',
), $text);
}
return $text;
}