Hi
I'm looking for some building blocks or alternatives for the v3 functions of fieldset (or rather: container/fieldset) and server side validation.
Right now I'm inserting custom html elements to open and close the fieldset, but maybe there's a smarter way?
What's the best approach to do some custom server side validation?
kind regards
Stijn
I had some problem with containers too. See https://www.chronoengine.com/forums/posts/t103661/how-to-create-containers-do-separete-elements.html
You will have to try using the Areas elements to mimic the fieldset. You can try using the Segment element. See more about it https://semantic-ui.com/elements/segment.html
Regarding server side validation, I'm trying to understand that too. I do think that the best approach is using a PHP block followed by a Event switch block.
Hi Stijn,
If you are using custom HTML then this is not a bad solution, I will try to have a fieldset area in the next update.
server validation can be done with the "Validate data" action, in the data provider write {data:}, then write each field you want to validate with the validation rule and error message:
field1/required:this field is required
field1/email:it should have an email address
If you need a custom function then you can do that with a PHP block and event switcher like flashfs noted, the PHP should return the value to be switched then use {var:php_name} in the data provider of the event switcher.
https://www.chronoengine.com/faqs/74-chronoforms6/5293-validating-fields.html
Best regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.