formtools / core

The Form Tools Core.
https://formtools.org
207 stars 78 forks source link

Need to process based on multiple criteria - hitting a wall - any help much appreciated #722

Closed taskvalanche closed 4 years ago

taskvalanche commented 4 years ago

So I'm trying to figure out how to generate a "go/no go" response based on multiple criteria so I need an "if a>2 OR if b=false OR" etc. etc. The problem is the regular filters appear to only work as AND filters so that's out.

I tried using the pre-parser mod but as soon as I turn any rule on I get a 500 error. Nothing in the Apache logs, just "surprise, 500!" so I can't even tell what's going wrong there.

I tried client-side JavaScript to set a hidden form field to a boolean value if any part of the form goes off-criteria. That gives me random values totally unrelated to the criteria set in the field.

The only thing left I can think of is to use PHP directly in the form to read the fields and write to the column in the database, is that the only way to reliably do this?