Ejemplo n.º 1
0
 public function beforeRender(WpTesting_Model_Test $test, WpTesting_Model_Passing $passing = null)
 {
     $this->test = $test;
     $this->passing = $passing;
     $passing->setIp($this->getClientIp())->setDeviceUuid($this->extractUuid('device_uuid', $_COOKIE))->setUserAgent($this->getUserAgent())->setRespondentId($this->wp->getCurrentUserId());
     try {
         $passing->storeAll();
         $link = $passing->getUrl($this->getCurrentUrl());
         return $this->redirectAndDie($link);
     } catch (fValidationException $e) {
         return $this->dieNotValid($e->getMessage());
     }
 }