/** * Display author details page. * * @return \Symfony\Component\HttpFoundation\Response */ protected function details() { $this->author->get_rating(); // Canonical URL $this->template->assign_var('U_CANONICAL', $this->author->get_url()); return $this->helper->render('authors/author_details.html', $this->get_title('AUTHOR_DETAILS')); }
break; /** * Rate something & remove a rating from something */ /** * Rate something & remove a rating from something */ case 'rate': $type = request_var('type', ''); $id = request_var('id', 0); $value = request_var('value', -1.0); switch ($type) { case 'author': $object = new titania_author(); $object->load($id); $object->get_rating(); $redirect = $object->get_url(); if (!$object || !$object->author_id) { trigger_error('AUTHOR_NOT_FOUND'); } break; case 'contrib': $object = new titania_contribution(); $object->load($id); $object->get_rating(); $redirect = $object->get_url(); if (!$object) { trigger_error('CONTRIB_NOT_FOUND'); } break; default: