You are here

function MarkdownExtra_Parser::doFootnotes in Markdown 6

Same name and namespace in other branches
  1. 5 markdown.php \MarkdownExtra_Parser::doFootnotes()

File

./markdown.php, line 3067

Class

MarkdownExtra_Parser

Code

function doFootnotes($text) {

  #

  # Replace footnote references in $text [^id] with a special text-token

  # which will be replaced by the actual footnote marker in appendFootnotes.

  #
  if (!$this->in_anchor) {
    $text = preg_replace('{\\[\\^(.+?)\\]}', "F\32fn:\\1\32:", $text);
  }
  return $text;
}