Same Event Action for multile Returned Value in PHP Action Trigger Events

Use the same event action for multiple returned values in a ChronoForms PHP action trigger.

Overview

The PHP action returns multiple values, but the trigger only allows one return value to be mapped to a specific event.
Modify your PHP code to return a single consistent value, like 'fail', for all non-success outcomes, then set that value in the trigger's 'Return Value' field.

Answered
ChronoForms v7
sh shahabpk 17 Feb, 2026

I have a PHP Action on Submit event and this action has an event trigger which trigger events based on returned value. My PHP returns multiple values like 'success' and few other error returns as error message. I want two events one for success and other for all other returns except 'succcess'. How this can be done. What value should be given in the 'Return Value' field. 

Screenshot 2026-02-17 134213.png
Max_admin Max_admin 29d ago
Answer

Just make your PHP code return the same "fail" string for ALL other events and that would make it work with your current setup.

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Post a Reply