Разработка информационной системы управления учебным процессом (на примере филиала РГГУ г. Всеволжска)
Дипломная работа - Компьютеры, программирование
Другие дипломы по предмету Компьютеры, программирование
mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);
(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);($k=1; $k
" ;
$id=""; $Name="";
};
};
};
$result->close();
$mysqli->close();
}
id_info_lectures($kaf){
$ids=getinfo("SELECT `id` FROM `lectures` where `Departmen_id`=$kaf");($ids as $id){ echo "";($kaf) $sql="SELECT `id`, `Surname`,`Name`,`Patronymic`,`Stepen_id`,`Departmen_id`,`items_id` FROM `lectures` where `Departmen_id`=$kaf and id=$id";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);( $result->fetch_assoc() as $key => $value){($key=="Stepen_id")$value=get_stepen_name ($value);($key=="Departmen_id")$value=get_kaf_name ($value);($key=="items_id")$value=get_items_name ($value);"";
$value="";
}
$result->close();
$mysqli->close();
(!$kaf)echo "
";
};
}
get_all_kaf_li(){
$ids=get_all_kaf_id();($ids as $id){"" ;
}
}get_all_predm_li(){
$ids=get_all_predm_id();($ids as $id){"" ;
}
}
get_all_predm_li_ved(){
$ids=get_all_predm_id();($ids as $id){"" ;
}
}
get_all_group_li_a(){
$ids=get_group_id();($ids as $id){"\n" ;
}
}get_all_kaf_dep(){
$count=getinfo("SELECT count(`id`) from `Departments`");
$count=$count[0];
$sql="SELECT `id`, `Name`, `ZavDepartment` from `Departments`";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);
(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);
($k=1; $k
" ; $id=""; $Name=""; $zav="";
};
};
};
$result->close();
$mysqli->close();$data;
}
del_student($id){
$sql="DELETE FROM `students` where `id`=$id";($sql);1;
}
del_group($id){
$sql="DELETE FROM `group` where `id`=$id";($sql);1;
}
del_lectures($id){
$sql="DELETE FROM `lectures` where `id`=$id";($sql);1;
}
del_kaf($id){
$sql="DELETE FROM `Departments` where `id`=$id";($sql);1;
}del_spec($id){
$sql="DELETE FROM `spec` where `id`=$id";($sql);1;
}del_predm($id){
$sql="DELETE FROM `predm` where `id`=$id";($sql);1;
}
get_all_kaf_id(){
$sql='SELECT `id` FROM `Departments`';(getinfo($sql));
}
get_all_predm_id(){
$sql='SELECT `id` FROM `predm`';(getinfo($sql));
}get_all_spec_id(){
$sql='SELECT `id` FROM `spec`';(getinfo($sql));
}get_all_group_id(){
$sql='SELECT `id` FROM `group`';(getinfo($sql));
}
get_all_stud_id(){
$sql='SELECT `id` FROM `students`';(getinfo($sql));
}
get_all_stepen_id(){
$sql='SELECT `id` FROM `stepeni`';(getinfo($sql));
}
get_predm_ved($predm){"";
$sql="SELECT `id`, `id_stud`,`id_pred`,`ocenka` FROM `vedomosti` where `id_pred`=$predm";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);( $result->fetch_assoc() as $key => $value){($key=="id_stud")$value=get_fio_student ($value);($key=="id_pred")$value= get_predm_name ($value);"";
}
$result->close(); $mysqli->close();"";
}get_fio_student($id){
$sql="SELECT `Surname` FROM `students`";
$x=getinfo($sql);
$fio.=$x[0];
$sql="SELECT `Name` FROM `students`";
$x=getinfo($sql);
$fio.=' '.$x[0];
$sql="SELECT `Patronymic` FROM `students`";
$x=getinfo($sql);
$fio.=" ".$x[0];$fio;
}
get_all_kaf_sel(){
$ids=get_all_kaf_id();"";($ids as $id){
$sql="SELECT `Name` FROM `Departments` where `id`=$id";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);( $row = $result->fetch_assoc() ){($row as $fieldValue){"\n";
}
}
$result->close();
$mysqli->close();
};1;
}
get_all_stud_sel(){
$ids=get_all_stud_id();"";($ids as $id){
$sql="SELECT `Name` FROM `students` where `id`=$id";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);( $row = $result->fetch_assoc() ){($row as $fieldValue){"\n";
}
}
$result->close();
$mysqli->close();
}; return 1;
}
get_all_spec_sel_opt($id){
$ids=get_all_spec_id();($ids as $id){
$sql="SELECT `Name` FROM `spec` where `id`=$id";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);
( $row = $result->fetch_assoc() ){($row as $fieldValue){($id==$fieldValue)$x="disabled";"\n";
}
}
$result->close();
$mysqli->close();
};1;
}get_all_kaf_sel_opt($id){
$ids=get_all_kaf_id();($ids as $id){
$sql="SELECT `Name` FROM `Departments` where `id`=$id";
$mysqli = new mysqli(HOST_DB, DB_USER, DB_PASS, DB_NAME);(mysqli_connect_errno()) {("Connect failed: %s\n", mysqli_connect_error());
}
$mysqli->query('SET NAMES utf8');
$result = $mysqli->query($sql);( $row = $result->fetch_assoc() ){($row as $fieldValue){($id==$fieldValue)$x="disabled";"\n";
}
}
$result->close();
$mysqli->close();
};1;
}
get_all_predm_se