Is it possible to combine PHP's filter_input() filter flags with AND/OR?
<p>Various <a href="http://php.net/manual/en/filter.filters.flags.php" rel="nofollow">filter flags</a> can be used with PHP's <a href="http://php.net/manual/en/function.filter-input.php" rel="nofollow"><code>filter_input()</code></a> function.</p>

<p>For example, if I want to retrieve the value of a scalar POST field, I can use the default, without specifying the filter. Or, if I I'm dealing with an array POST field, I'd use the corresponding filter:</p>

<pre><code>$scalar = filter_input(INPUT_POST, 'field');
$array = filter_input(INPUT_POST, 'field', FILTER_DEFAULT, FILTER_REQUIRE_ARRAY);
</code></pre>

<p>Is it possible to combine the filter flags with either <code>AND</code> or <code>OR</code>? For example, with <code>OR</code>:</p>

<pre><code>$value = filter_input(INPUT_POST, 'field', FILTER_DEFAULT, FILTER_REQUIRE_SCALAR || FILTER_REQUIRE_ARRAY);
</code></pre>

<p>A possible use case for this would be looping over POST fields, some of which can be arrays. e.g.,</p>

<pre><code>foreach ($fieldSet as $field)
{
    $value = filter_input(INPUT_POST, $field, FILTER_DEFAULT, FILTER_REQUIRE_SCALAR || FILTER_REQUIRE_ARRAY);
    ...
}
</code></pre>