If nothing else, Contao normally passes through all of the form data to the redirect (i.e. thank you) page that you set.
If I remember correctly, they come through as GET variables and also SESSION variables.
So after submitting the first form, on your redirect page you can add some logic to redirect again depending on the value of a submitted field.
For example, if you can find a place for this in a template on that page:
Code:
<?php $this->redirect($_GET['age'] > 18 ? 'formA.html' : 'formB.html'); ?>
I don't know if this is the most elegant solution, but it should get you there.
A couple of other things I would check is that EFG (which admittedly I haven't used in a real project, yet, but plan to) implements or ties in with the existing Contao hooks or perhaps even provides ones on its own. If so it would be better to put the above code in something like that instead.
For example in the core there is a 'processFormData' hook, where you can intercept the submitted data and do some PHP magic on it. If EFG has that hook, or something similar, that would be your best bet. But here you'd put your code in your own folder under "modules" and wouldn't need to have an extra page just to do the redirect, nor have to shoehorn it into a template somewhere.
Maybe others have ideas as well...
Bookmarks