UserId)){ $vote->UserId = Session::$User->UserId; $vote->User = Session::$User; } $poll = Poll::GetByUrlName(HttpInput::Str(GET, 'pollurlname')); try{ $vote = PollVote::Get($poll->UrlName, Session::$User->UserId); // Vote was found, don't allow another vote. throw new Exceptions\PollVoteExistsException($vote); } catch(Exceptions\PollVoteNotFoundException){ // Vote was not found, user is OK to vote. } if($exception){ http_response_code(Enums\HttpCode::UnprocessableContent->value); session_unset(); } } catch(Exceptions\LoginRequiredException){ Template::RedirectToLogin(); } catch(Exceptions\PollNotFoundException){ Template::Emit404(); } catch(Exceptions\PollVoteExistsException $ex){ $redirect = $poll->Url; if($ex->Vote !== null){ $redirect = $ex->Vote->Url; } header('Location: ' . $redirect); exit(); } ?> $poll->Name . ' - Vote Now', 'highlight' => '', 'description' => 'Vote in the ' . $poll->Name . ' poll']) ?>

Vote in the Name) ?> Poll

$exception]) ?>

Select one of these options.

    PollItems as $pollItem){ ?>