<?php
/* vim: set expandtab tabstop=4 shiftwidth=4 foldmethod=marker: */

# Allows to choose and evaluate a subject
# @author Igor Támara igor@tamarapatino.org
# Public domain. 2003. No warranties. http://structio.sourceforge.net/sigue

session_start();

require "auth/confcol.php";

$title="Valoraciones de ".$_SESSION["teacher"]." en ".$_SESSION['periodo'];
require "header.php";
if (!isset($_SESSION["autenticado"])||$_SESSION["autenticado"]==false) {
  require "footer.php";
  exit;
}
if(!isset($_SESSION['curso'])) {
	unset($_SESSION['curso']);
	session_unregister("curso");
}
require "TeacherCourses.php";
$my_courses = new TeacherCourses($GLOBALS["DIRCOL"],$_SESSION['año'],$_SESSION["teacherdir"]);
$courses=$my_courses->values();
$_SESSION["accion"]="valorar";
foreach ($courses as $key=>$course) {
  $my_course=explode(":",$course);
  $cursos[$key]=$my_course[1]." en ".$my_course[0];
}
print "<div align=\"center\">
<form action=\"valorarmateria.php\" method=\"post\">
<table border=\"0\">
<tr><td>";
asort($cursos);
showselect($cursos,"curso");
print "<tr><td align=\"center\"><input type=\"submit\" value=\"".
	$_SESSION["accion"]."\">
</table>
</form>
</div>";
require "footer.php";
?>
