function setCounter() { $cnt = $this->getData('session.counter'); $this->setData('session.counter', ++$cnt); }