title icon 學務系統交流網
menu_top_background
:::
設定國中小校差別
::: 託管學校資料庫中的 school 資料表
 
說明:
 
include/config.php
 
//檢查是否改變學校
if (!$IS_SCHOOL_LIST) {
        session_start();
        if(!get_exist_teacher_sn()){
                session_destroy();
        }
}
if ($IS_JHORES == 6){
        // 年段
        $class_year = array("7"=>"一年","8"=>"二年","9"=>"三年","a"=>"補校","b"=>"特教班","c"=>"資源班");
}
else {
        $class_year = array("1"=>"一年","2"=>"二年","3"=>"三年","4"=>"四年","5"=>"五年","6"=>"六年","a"=>"幼稚園","b"=>"特教>班","c"=>"資源班");
}
// 班名
$class_name = array("01"=>"甲","02"=>"乙","03"=>"丙","04"=>"丁","05"=>"戊","06"=>"己","07"=>"庚","08"=>"辛");
 
include/sfs_school_set.php
 
//檢查資料庫是否建立
$query = "select  a.server_ip,a.db_ip,db_user,a.db_pass,b.sch_id,b.sch_name,b.is_jhores from server a,school b where a.server_id=b.server_id and b.sch_id='$_COOKIE[cookie_sch_id]' and b.is_open=1";
$res = $CONN_M->Execute($query) or trigger_error($query);
if ($res->Recordcount()>0) {
        $mysql_host = $res->fields[db_ip];
        $mysql_user = $res->fields[db_user];
        $mysql_pass = $res->fields[db_pass];
        $sch_name = $res->fields[sch_name];
        $IS_JHORES = $res->fields[is_jhores];
        $mysql_db = "s".$res->fields[sch_id];
        $SFS_PATH_HTML = $res->fields[server_ip]."/";
}
 
註: $IS_JHORES  值 小學為 0  ,國中為 6 ,預設為 0 如果是國中要託管要手動進入修改.
影響,如 學生成績補登 , 問題工具箱模組等.
 
如果是自架的只要檢查 config.php 設定檔即可.
menu_bottom_background

::: copy right: 苗栗縣政府教育處資訊中心
建議使用瀏覽器Firefox或Chrome