fuel/core — Issue #687: Include ampersand as punctuation in valid_string validator
Author: jasonsocha
Created: 2011-11-24 00:46:40+00:00
State: open

Currently, there is no way to pass valid_string if an ampersand is present in the value - it is not matched by any of the available patterns. Ampersand is a relatively common punctuation mark in english, so I suggest that it be included.

This could be achieved by making the following change in the Validation class:

Current: `836 $pattern .= in_array('punctuation', $flags) ? "\.,\!\?:;" : '';`
Proposed: `836 $pattern .= in_array('punctuation', $flags) ? "\.,\!\?:;\&" : '';`