[Pmwiki-users] How "function:PrintText some text" behaves
John Rankin
john.rankin
Wed Aug 6 20:08:21 CDT 2003
When I write
$PublishList[] = "function:PrintText ----";
$PublishList[] = "function:PrintText !$number $name";
and subsequently call
$PrintFmt($pagename...);
I see, as expected, a horizontal rule followed by a heading 1.
However, if I write
$PublishList[] = "function:PrintText ----\n!$number $name";
I see the string
function:PrintText ----!1 PageName
(or whatever the values of $num and $name are).
The \n is presumably the culprit. When I look at the PrintFmt source, there is a line that looks for
"function:" followed by a word, followed by spaces, followed by (.*) -- I assume it gets to the \n and stops in confusion. Looking back to earlier postings, would an "s" modifier at the end of the preg_match fix this?
It's no big deal, but can anyone shed light? Thanks...
--
John Rankin
More information about the pmwiki-users
mailing list