public function hasAncestor(Element $element)
 {
     if ($this->parent === null) {
         return false;
     }
     if ($this->parent->getType() == Token::ELEMENT && $this->parent->getName() == $element->getName()) {
         return true;
     }
     return $this->parent->hasAncestor($element);
 }
Example #2
0
 protected function getAllowedAttributes()
 {
     $colgroupAllowedAttributes = array('/^span$/i' => Attribute::INT);
     return array_merge($colgroupAllowedAttributes, parent::getAllowedAttributes());
 }