Source for file Footnote.php
Documentation is available at Footnote.php
* This class implements a Text_Wiki_Rule to find source text marked for
* strong emphasis (bold) as defined by text surrounded by two
* stars. On parsing, the text itself is left in place, but the
* starting and ending instances of two stars are replaced with
* @author Paul M. Jones <pmjones@php.net>
* @author Michele Tomaiuolo <tomamic@yahoo.it>
* @version $Id: Footnote.php 236407 2007-05-26 17:47:24Z mic $
* The regular expression used to parse the source text and find
* matches conforming to this rule. Used by the parse() method.
var $regex = "/(\n)*\[([0-9]+)\]/";
* Generates a replacement for the matched text. Token options are:
* 'type' => ['start'|'end'] The starting or ending point of the
* emphasized text. The text itself is left in the source.
* @param array &$matches The array of matches from parse().
* @return A pair of delimited tokens to be used as a placeholder in
* the source text surrounding the text to be emphasized.
if ($matches[1 ] == "\n") {
$token = $this->wiki->addToken (
array ('text' => " [$id]" , 'href' => $href, 'name' => $name, 'type' => 'inline')
return $matches[1 ] . $token;
Documentation generated on Mon, 11 Mar 2019 15:40:30 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|