Source for file Anchor.php
Documentation is available at Anchor.php
* This class implements a Text_Wiki_Parse to add an anchor target name
* @author Manuel Holtgrewe <purestorm at ggnore dot net>
* @author Paul M. Jones <pmjones at ciaweb dot net>
* The regular expression used to find source text matching this
* rule. Looks like a macro: [[# anchor_name]]
var $regex = '/(\[\[# )([-_A-Za-z0-9.]+?)( .+)?(\]\])/i';
* Generates a token entry for the matched text. Token options are:
* 'text' => The full matched text, not including the <code></code> tags.
* @param array &$matches The array of matches from parse().
* @return A delimited token number to be used as a placeholder in
$start = $this->wiki->addToken (
array ('type' => 'start', 'name' => $name)
$end = $this->wiki->addToken (
array ('type' => 'end', 'name' => $name)
// done, place the script output directly in the source
return $start . trim($text) . $end;
Documentation generated on Mon, 11 Mar 2019 14:22:30 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|