addError('pa_var_course_empty'); redirect('../../admin/index.php'); } else { $link=$base_path.'mods/photo_album/admin_image_list.php'; $template=new HTML_Template_ITX("./Template"); $template->loadTemplatefile("index_admin.tpl.php", true, true); $template->setVariable("TITLE", _AT('pa_title_admin_index')); $template->setVariable("MESSAGE", _AT('pa_note_admin')); $template->setVariable("FORM_NAME", "photo_form"); $template->setVariable("FORM_ACTION", $link); $template->setVariable("SELECT_NAME", "course_id"); for ($i=0; $isetCurrentBlock("OPTION_VALUE"); $template->setVariable("VALUE", $courses[$i]['id']); $template->setVariable("TEXT", $courses[$i]['title']); $template->parseCurrentBlock("OPTION_VALUE"); } $template->setVariable("SUBMIT_NAME", "submit"); $template->setVariable("SUBMIT_VALUE", _AT('pa_tag_go')); $template->parseCurrentBlock(); $template->show(); } ?>