I have a very strange occurrence.
Within a Submit I have an Event Switcher and inside there are 3 further Event Switchers.
The first and third of these Event Switchers have the expected values set as Tennis, Squash, Tennis & Squash
The first one accepts fields in all 3 event boxes.
The third one does not accept fields in the event box for Tennis & Squash. Fields can be placed into the box but on saving the form the box is emptied.
If I change the value to TennisSquash without any spaces the fields get accepted and remain after the form is saved.
Wallyhowe
Hi wallyhowe
That's expected, do not use spaces in the events names, the value you switch should provide them without spaces
Hi Max
Interesting that the string value to be tested was accepted higher up the form.
Also, this form is an upgrade from a Chronoforms 7 form where the equivalent worked fine. So in effect this is a change between 7 and 8.
Whatever, is the recommended way of using the Event Switcher in 8, where the field to be tested is a string that may contain spaces, to test the value using PHP and return a variable that becomes the subject of the test?
Wallyhowe
Hi Wallyhowe
it's just an untested part and the result is unexpected, I advice against using spaces in events names, if it works for you then that's fine
I tested it and it works if you drag the field and drop it outside the event switcher first, then drag it inside the switcher
What is your events provider ? if it's a field data like a dropdown then make sure all values are without spaces, but if you are switching a more complex value then you can use PHP, PHP has it's own Events behavior which you can use directly for the switching