[pmwiki-users] Preformatted text following heading

Patrick R. Michaud pmichaud at pobox.com
Sun Feb 19 13:31:28 CST 2006


Joachim Durchholz wrote:
> On a tangent, I noticed that PmWiki has an interesting deviant behavior 
> if a ! line is followed with [@: it will run the preformatted text into 
> the header. 
> [...]
> --- snip ---
> !!Get and run @@debootstrap@@
> [@
> cd /tmp
> w3m ${local_mirror}/pool/main/d/debootstrap/
> @]
> --- snip ---
> and hit the Preview button.

Weird.  Something on that system is causing it to eat
the newline after the heading whenever the heading
is immediately followed by a multiline [@...@] block.

It only does it for multiline [@...@] blocks -- it doesn't
do it for a single-line [@...@].

Weirder still -- it's eating vspace paragraphs.  The markup

    !!Get and run

    [@
    cd /tmp
    w3m ${local_mirror}/pool/main/d/debootstrap/
    @]

ought to have a vspace paragraph between the <h2> and the
<pre> block, but it doesn't appear.  (The vspace does appear
if the [@...@] is a <code> block, or any other form of text.)

What makes this especially bizarre is that vspace paragraphs
aren't simple blank lines in the markup, one of the first steps
before processing any markup rules is to convert "\n\n"
into "\n<:vspace>\n".  So whatever is happening is sufficient
to eat up a "<:vspace>" string, as well as a newline.

I'm pretty stumped on this one.  What version of PHP, and
what OS?

Pm




More information about the pmwiki-users mailing list