Forums

switch bug

rafaelscouto 12 Apr, 2019
1 Likes
I realized that some functions I use with switch have stopped working.

For example: Checking if data recording occurred, the message no longer appears.
Max_admin 12 Apr, 2019
What do you have the switch "data provider" ?
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
rafaelscouto 12 Apr, 2019
In the data provider of my switch I have {var: save_contract}

When saving nothing is displayed on the screen.

It was working before the last update I made
Max_admin 13 Apr, 2019
And what are the values of the switch ?
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Max_admin 13 Apr, 2019
1 Likes
The save data returns either false on failure or an array of saved data on success, so just change "true" to "*" and it should work, and make false first:
false:error message
*:success message
OR change the data provider to: {var.empty:save_edit_cad_cred}

This returns the "empty" test of the variable which should work with your existing values!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
rafaelscouto 13 Apr, 2019
It's working
Thanks!

Get me a question about redirection.
save event

I always leave a message of success or error to the end
{fn: check_update_result}

But, I would like to make a redirect.
If I put this {redirect: index} at the end

{fn: check_update_result}
{redirect: index}

The redirect happens, but the message is not shown, how can I resolve it?
This topic is locked and no more replies can be posted.