Пример #1
0
/**
 * Alias of `filter\intl\chars(true, true, true)`.
 */
function alnum($whitespace = false)
{
    return filter\intl\chars(true, true, true, $whitespace);
}
Пример #2
0
 /**
  * @covers       ::plan\filter\intl\chars
  * @dataProvider testCharsProvider
  */
 public function testChars($lower, $upper, $number, $whitespace, $input, $expected)
 {
     \setlocale(LC_ALL, 'en');
     $validator = new plan(filter\intl\chars($lower, $upper, $number, $whitespace));
     $validated = $validator($input);
     $this->assertEquals($expected, $validated);
 }