Jul 29th, 2011, 9:11 AM
Hi Fraser,
Sorry I totally missed your response.
Sure! Here's how it would work. First, just download and install the Submission Pre-Parser module:
http://modules.formtools.org/submission_pre_parser/
Then, inside the module, create a new rule that's assigned to your form. Make sure it's set to be triggered "on submission" (i.e. when the submission is first submitted).
Lastly, in the PHP aread
What that code does is look for a form field with a name attribute of "something", then if it has a particular value (value 1, value 2 or value 3), set the redirect URL to something different.
You'll need to change those values to whatever makes sense, but that's the idea!
- Ben
Sorry I totally missed your response.
Sure! Here's how it would work. First, just download and install the Submission Pre-Parser module:
http://modules.formtools.org/submission_pre_parser/
Then, inside the module, create a new rule that's assigned to your form. Make sure it's set to be triggered "on submission" (i.e. when the submission is first submitted).
Lastly, in the PHP aread
PHP Code:
if ($_POST["something"] == "value 1") {
$_POST["form_tools_redirect_url"] = "http://www.site1.com";
} else if ($_POST["something"] == "value 2") {
$_POST["form_tools_redirect_url"] = "http://www.site2.com";
} else if ($_POST["something"] == "value 3") {
$_POST["form_tools_redirect_url"] = "http://www.site3.com";
}
What that code does is look for a form field with a name attribute of "something", then if it has a particular value (value 1, value 2 or value 3), set the redirect URL to something different.
You'll need to change those values to whatever makes sense, but that's the idea!
- Ben