Example form is linked to a database table, but won't be saved in this example.
When you submit the form, the value is presented with debug_dump(), so strings are quoted and array values listed.
<?php $field = new form_field_email($form, 'Email'); $field->db_field_set('email'); // $field->domain_check_set(false); // $field->domain_error_set('Your email does not appear to be for a valid domain.', 'Tick if you are sure this is valid.'); $field->format_error_set('Your email does not appear to be correct.'); $field->min_length_set('Your email is required.'); $field->max_length_set('Your email cannot be longer than XXX characters.'); ?>