hasAttribute('tabindex')) { $tabindex = $element->getAttribute('tabindex'); if (is_numeric($tabindex)) { $val = (int)$tabindex; if ($val > 0) { return $this->createViolation( $element, "Avoid positive tabindex values (tabindex=\"{$val}\") to preserve the natural tab order.", "Remove the positive tabindex or change it to \"0\" or \"-1\"." ); } } } return null; } }