[pmwiki-users] Pagelist wrap= parameter documentation error?

Oliver Betz list_ob at gmx.net
Sun May 24 09:47:30 CDT 2009


update:

my findings after reading older revisions of the sources:

wrap has been added in 2.2.0-beta56 dated 2007-06-13:

>* The (:pagelist:) directive now supports "wrap=inline" and "wrap=HTML"
>  options, which allows the output from pagelist (markup or HTML)
>  to be directly embedded in a page's markup or without any surrounding
>  <div>...</div> tags.

As far as I see, this announcement contains an error, it should read
"wrap=inline and wrap=_none_", not HTML. The wrap parameter is nowhere
checked for being 'HTML'.

BTW: The default value for the "wrap" parameter 'div'. I don't know
what this is good for.

"wrap=none" suppresses the surrounding <div> class=...</div> tags.

"wrap=inline" suppresses the <div> class=...</div> tags and the call
to $FPLTemplateMarkupFunction (being MarkupToHTML by default). I'm not
able to describe exactly the effects of this switch because I don't
know when MarkupToHTML is intended to be applied. Since I get HTML
from a wrap=inline list, the markup has been processed at least once
by MarkupToHTML, anyway.

BTW: Likely wrap= might be considered not to be accessible from a
search box: Adding wrap=inline to a search request yields garbled
output.

There is another undocumented pagelist parameter 'class'.

The general default value used in FPLTemplate() is fpltemplate, but
there are also default values in the $FPLFormatOpt array for the
'bygroup', 'simple', 'group' and 'title' page list formats. Shouldn't
these defaults be set in the pagelist templates?

I will wait a few days for comments - maybe someone can explain the
MarkupToHTML stuff - and then update the docs.

Oliver




More information about the pmwiki-users mailing list