FPLTemplate-Talk

Discussion re FPLTemplate

Is 'bygroup' intentionally not included in using the FPLTemplate2? I'm looking at the settings for $FPLFormatOpt... Peter Bowers March 14, 2009, at 07:13 AM

no. It is there, part of SDVA($FPLFormatOpt, array(..)); - HansB March 14, 2009, at 08:13 AM

It is there, but it uses 'fn'=>'FPLTemplate' rather than 'fn'=>'FPLTemplate2'. At least in the copy I downloaded a couple hours ago...

Looks like an oversight. Could you update the file please? thanks - Hans

Done. Peter Bowers March 15, 2009, at 04:29 PM


I recall discussing the use of array_merge() in FPLTemplatePageList() and I liked the idea at the time (may have suggested it? don't remember...). Now in retrospect I'm wondering if array_intersect() isn't more appropriate. I'm playing around with a function which will provide some of the desired functionality in link=x where x can include wildcards, etc. And I'm realizing that each separate search term needs to be logically connected with the others via "and". In other words, if I come up with a list of a,b,c,d which match a link-specification, but MakePageName comes up with c,d,e,f that match a given term then the user presumably was interested in c,d rather than a,b,c,d,e,f. I'm thinking interection makes sense in the big picture as the default and then maybe at some point in the future there would be some way of expressing union with the array_merge() instead...

...(lengthy discussion implemented as proof-of-concept and moved to PageListPlus)...

Anyway, I'm getting ahead of myself. I think the suggestion right now is to change the default behavior to use intersection rather than union.

Peter Bowers March 14, 2009, at 09:20 AM


Could I suggest the following enhancements, I've been thinking about them for some time, and your excellent recipe prompts me to propose them.
In (:template each:) it could be useful to have if means to:

exit the pagelist
eg (:if condition:)(:template exit:)(:ifend:)
continue to next iteration (increment count)
increases to count and goes to the next iteration, eg (:template continue:)
continue to next iteration (don't increment count)
go to next iteration without increasing count, eg (:template next:)

Note that continue and next could be enhanced further by allowing "next group" or "continue group"

thanks simon

Talk page for the FPLTemplate recipe (users?).