[pmwiki-users] remove markup rules for just one run of MarkupToHTML

Peter Bowers pbowers at pobox.com
Thu Mar 25 08:54:53 CDT 2010

On Wed, Mar 24, 2010 at 8:29 PM, Carlos AB <cabsec.pmwiki at gmail.com> wrote:
> I'm trying to make MarkupToHTML() put html inside a textarea, the
> problem is that I need (:if:), (:pagelist:), and some other markups to
> be changed for just one run and not subsequent runs.
> I tried DisableMarkup() but it changes the markup for all  runs of
> MarkupToHTML()  and it won't process (:if:) in Site.PageActions ,
> *.GroupHeader|Footer pages and others.
> How can I disable certain Markups for just one run of MarkupToHTML?

The building of the table of markup rules and the ordering of that
table and etc is the heart, the genius behind pmwiki.  It is
incredibly powerful and very flexible ... to a point.  I am not aware
of any way to do what you are looking for.

However, maybe you could look at it differently.  If there are a
certain subset of rules that you need to apply then the toolbox recipe


offers the function RunMarkupRules() which allows you to create your
own mini-table of rules and run those rules over some markup text.
For instance, in a recipe I often want to allow comments and
conditional processing and include capabilities on pages -- so I just
run those 3 rules over my page before I start using the text -- that
greatly enhances the functionality & flexibility of a recipe...

But if you are looking for the full set of rules or even a large
majority of them it probably isn't too practical to build the whole
rule table -- although I suppose ultimately it's not that big a
deal...  Theoretically there's probalby some array in pmwiki you could
traverse to build this array and leave something out as well -- I've
just never looked into that particular capability...


More information about the pmwiki-users mailing list