Fixed bad url in theme page
This commit is contained in:
parent
31eabf84b4
commit
5656d116af
3 changed files with 22 additions and 7 deletions
|
|
@ -5,9 +5,16 @@ if(!defined('ONYX')) exit;
|
|||
$p = $out[0];
|
||||
|
||||
if (isset($p[2]))
|
||||
$template->assign("theme", $p[2]);
|
||||
{
|
||||
$tmp = explode("-", $p[2]);
|
||||
$id = intval($tmp[0]);
|
||||
if ($id == 0)
|
||||
return "404";
|
||||
$theme = new Theme($id);
|
||||
$template->assign("theme", $theme);
|
||||
}
|
||||
|
||||
if (isset($p[3]))
|
||||
$template->assign("ex", $p[3]);
|
||||
$template->assign("ex", new Exercice($p[3], $theme));
|
||||
|
||||
return "admin/exercice";
|
||||
return SALT_ADMIN."/exercice";
|
||||
|
|
|
|||
Reference in a new issue