• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Redirect based on calculation result

Redirect based on calculation result 3 years 9 months ago #40356

Hi

We need to setup a form where people can select up to 3 options using checkboxes where each will have a value. There needs to be a calculation based on their selection and then a redirect based on the value of the calculation result.
Selection a is 10
Selection b is 10
Selection c is 20

If they select a and c the result displayed by the calculation is 30 and they are redirected to a page z If they select a and b the result displayed is 20 and they are redirected to page y

I know that we can redirect depending on a selection but is it possible to do this and redirect based on the result of a calculation?

Thanks
The administrator has disabled public write access.

Redirect based on calculation result 3 years 9 months ago #40360

  • andreic
  • andreic's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 722
  • Thank you received: 59
Hello,

Can you please let me know when you would like to perform this redirect? After the "Thank you" message is shown and the user clicks the `Continue` button?

If this is the case the simplest solution would be using a hidden field in your form that will store the URL the user should be redirected to, you can then use the placeholder of this field in the "Return URL" configuration field.

The value of this hidden field can be set either through Javascript when the user makes a selection in your calculations fields or through a PHP script in "Scripts called on form process" based on the total amount calculated. Using a PHP script in the "Scripts called on form process" field to set the value of the hidden field will also allow you to perform the calculations using the "Form calculations" feature.
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!