protected function getMessage() { if (strstr($this->_template, '{getMessage}')) { $sess = new DreawSession(); $this->_template = str_replace('{getMessage}', $sess->getMess(), $this->_template); } return $this; }