public function getAttribute($name): string
    {
        if ($this->attributes->length === 0) { // Performance optimization
            return '';
        }
        $value = parent::getAttribute($name);
        return $value !== '' ? (strstr($value, 'html5-dom-document-internal-entity') !== false ? $this->updateResult($value) : $value) : '';
    }
public function getAttribute($name): string
    {
        if ($this->attributes->length === 0) { // Performance optimization
            return '';
        }
        $value = parent::getAttribute($name);
        return $value !== '' ? (strstr($value, 'html5-dom-document-internal-entity') !== false ? $this->updateResult($value) : $value) : '';
    }
public function getAttribute ( $ name ) : string { if ( $ this -> attributes -> length === 0 ) { // Performance optimization return '' ; } $ value = parent :: getAttribute ( $ name ) ; return $ value !== '' ? ( strstr ( $ value , 'html5-dom-document-internal-entity' ) !== false ? $ this -> updateResult ( $ value ) : $ value ) : '' ; }
Returns the value for the attribute name specified.

@param string $name The attribute name.
@return string The attribute value.
@throws \InvalidArgumentException
Returns the value for the attribute name specified .