From: Makoto Kuwata Date: 2004-03-20T07:41:37+09:00 Subject: Re: [ANN] Kwartz (2004-03-19) released Andreas, > Another question: > I have some if/elsif code at the top of my plogic file that sets a few > boolean variables to determine which parts of the template have to be > displayed. But the problem is that this code is moved to the bottom of > the resulting erb file, where it has no effect. > > I call kwartz with: > kwartz -l erb -p template.plogic template.html > template.erb How about this? template.html: -------------------- .... -------------------- template.plogic: -------------------- :elem(document) :set(var = condition ? value1 : value2) ## or if/else statement @stag @cont @etag :end -------------------- It is supposed that only :elem() or :macro statments should be appeared in presentation logic file in Kwartz. # I may add special macros something like BEGIN/END of awk. -- regards, kwa