function parse_script()
{
if ($this->parse_attributes() && $this->token === self::TOK_TAG_CLOSE && ($start = $this->pos) && $this->next_pos('</script>', false) === self::TOK_UNKNOWN) {
$len = $this->pos - 1 - $start;
$this->status['text'] = $len > 0 ? substr($this->doc, $start + 1, $len) : '';
$this->pos += 8;
$this->status['last_pos'] = $this->pos;
return true;
} else {
$this->addError('No end for script tag found');
return false;
}
}