logo       

problems with returns and paragraphs: msg#00137

web.wiki.pmwiki.user

Subject: problems with returns and paragraphs

Hi,

I implemented the following code in local.php

$DoubleBrackets['/^.menu\\s+(.+)/e'] = "MkMenu('$1')";

function MkMenu($number) {
global $pagename;
PrintFmt($pagename, "<div class='menulink'>");
PrintText($pagename, "$number");
PrintFmt($pagename,"</div>");
return "<? ?>";

in order to support a markup

.menu Main/Homepage
.menu AboutMe/Homepage
.menu [[$Edit Edit]]
.menu [[mailto:hugo@xxxxxxxxxxx Support]]


when I leave out the return value, I get unwanted paragraphs between the
menu entries.



This leads me to something I have in mind for some time.

PmWiki treats two subsequent line feeds as a paragraph. But this is not the
case when
authoring a list. IMHO

* the list entry
and the first entry
* the second list entry
and the second entry

should render as one list

* the list entry and
the first entry
* the second list entry and
the second entry

* the list entry
and the first entry

* the second list entry
and the second entry

might render as two lists with a paragraph in between:

* the list entry and
the first entry
<p/>
* the second list entry and
the second entry

what do u think?

--bernhard





<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise