[pmwiki-users] viewform in wikiforms

Peter Bowers pbowers at pobox.com
Fri Feb 18 08:42:39 CST 2011

I am making a recipe-collection form for a fundraise for our local
school.  (Cookbook & recipe as in the kind you eat, not the pmwiki

I am using wikiforms to collect and organize the data.

Certain fields are optional, but if they are there then they belong on
a line all by themselves.  If they are not there then I don't want a
blank line to be there.

Thus in my ViewTemplate I have text like this:

(:if ! equal "" "<notes>":)<notes>\\

As you can see my hope is if <notes> are blank then there would be no
\\{newline}, but if there's something in <notes> then we would have
\\{newline} after it.

The difficulty is that <notes> can have multiple lines in it.  And
(:if ...:) doesn't work at all if the (: is on a different line from
the :).

Is there any way to do a conditional like this that will allow for
comparing multiple lines?  Or is there some other way to accomplish my
goal of getting rid of the \\{newline} in the case of a blank <notes>


More information about the pmwiki-users mailing list