<?php require_once('includes/requirecompere.inc.php'); require_once('includes/course.lectureinfo.inc.php'); $CMD_TMPL_NAME='course.lectureinfo'; $cs_id=0+TGET('cs_id'); $mb_id_owner=current_mb_id(); $DBConn->connect(true); $course=db_load_course_by_id($DBConn,$cs_id); if ($mb_id_owner!=$course['mb_id_owner']) { redirect("./"); return; } $dataset['ADDNEW']=array(0); if (TGET('op')=='confirm') { $dataset['ENTERING']=array(); $dataset['CONFIRMING']=array(0); } else { $dataset['ENTERING']=array(0); $dataset['CONFIRMING']=array(); if (TGET('op')=='revise') { if ($_SESSION['reserv.inputcache.errorareas']) $dataset+=$_SESSION['reserv.inputcache.errorareas']; } else purge_array_by_key_prefix($_SESSION,'reserv.inputcache'); } if ($_SESSION['reserv.inputcache.domain']!='lecture.addnew') { purge_array_by_key_prefix($_SESSION,'reserv.inputcache'); $_SESSION['reserv.inputcache.data']=array(); } $_SESSION['reserv.inputcache.domain']='lecture.addnew'; $lecture_data=&$_SESSION['reserv.inputcache.data']; $dataset+=course_lecture_info_prepare_dataset($DBConn,$course,$lecture_data,get_user_time_zone()*60,$dataset['CONFIRMING']); ?>