php
require_once 'jiaowu.php';
$jwid=$_POST['jwid'];
$jwpw=$_POST[ 'jwpw'];
$jwsc=$_POST['jwsc'];
$isLogin = getLogin($jwid,$jwpw,$jwsc);
if ($isLogin == "예") {
session_start();
$xuenia = getXueNian($jwid);
$scoreArry = array();
<code>for ($i=0; $i < count($xuenia); $i++) { //每个学年两个学期 $scoreArry[] = get_td_array(getGrade($jwid,$xuenia[$i],"1"),"1"); $scoreArry[] = get_td_array(getGrade($jwid,$xuenia[$i],"2"),"2");}// $s=getGrade($jwid,$xuenia[$i],"2");// $_SESSION['name']=getName($s);// $_SESSION['college']=getCollege($s);$_SESSION['course']=getcoursecontent(getcourse($jwid));$_SESSION['score']=$scoreArry;Header("Location:show.php"); </code>
}else{
session_start();
$_SESSION['error']="errorLogin";
header("Location:index.php");
}
?>
보고된 오류가 없나요? else
에서 세션 시작을 제거했습니다.