feed.sql: add some files

This commit is contained in:
Li Chen 2013-11-05 00:35:35 +01:00
commit 097023a32a
3 changed files with 33 additions and 9 deletions

View file

@ -2,9 +2,24 @@
if(!defined('ONYX')) exit;
$exercice = new Exercice($EXERCICE);
try
{
$exercice = new Exercice($EXERCICE);
$template->assign("Exercice", $exercice);
//$template->assign("Number", $ex_number);
if (!isset($exercice->id))
return "404";
return "teams/exercice";
if (!isset($exercice->theme) || $exercice->theme->name != $THEME)
return "404";
$solved = count($exercice->get_solved());
$template->assign("Exercice", $exercice);
$template->assign("solved", $solved);
return "teams/exercice";
}
catch(Exception $e)
{
return "404";
}