Hide PHP Warning: substr_compare() The length cannot exceed initial string length

pull/181/head
Aleksander Machniak 10 years ago
parent 7883ecb8ec
commit 7a6dd9ad84

@ -285,7 +285,7 @@ class html
// ignore not allowed attributes
if (!empty($allowed)) {
$is_data_attr = substr_compare($key, 'data-', 0, 5) === 0;
$is_data_attr = @substr_compare($key, 'data-', 0, 5) === 0;
if (!isset($allowed_f[$key]) && (!$is_data_attr || !isset($allowed_f['data-*']))) {
continue;
}

Loading…
Cancel
Save