Allow Multiple Emails in Custom Fuel Module Email Field
How do you override the default Fuel behavior that validates a field in a custom module containing the word "email" in order to allow multiple emails separated by commas? I have code that pulls in this email field to send an email to that recipient and my client is asking if we can specify multiple emails in the single email field, but Fuel's validation is preventing me from adding additional ones.
Anyway to override this behavior?
Erik
Comments
public $auto_validate_fields = array( 'email|email_address' => 'valid_email', 'phone|phone_number' => 'valid_phone' );
That basically means any field that has the word "email" or "email_address" will have the valid_email function tested against it during validation. If you blank out that value to an empty array you should be alright.