getinfo.php 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <?php
  2. PutEnv("NLS_LANG=RUSSIAN_CIS.CL8MSWIN1251");
  3. header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
  4. // always modified
  5. header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
  6. // HTTP/1.1
  7. header("Cache-Control: post-check=0, pre-check=0", false);
  8. // HTTP/1.0
  9. header('Cache-Control: no-cache, no-store, must-revalidate');
  10. header('Pragma: no-cache');
  11. header('Expires: 0');
  12. ?>
  13. <?php
  14. //if (isset($_POST["tabn"])) $mynzk=$_POST["tabn"]; else $mynzk="-1";
  15. if (isset($_POST["c_fam"])) $c_fam = trim($_POST["c_fam"]);
  16. else $c_fam = "empty";
  17. if (isset($_POST["tabn"])) $tabn = trim($_POST["tabn"]);
  18. else $tabn = "-1";
  19. $f = file_get_contents("http://172.16.0.55/api/get_information_rating_student.php?tabn=" . urlencode($tabn) . "&c_fam=" . urlencode($c_fam));
  20. $json = json_decode($f);
  21. if (isset($json->error))
  22. exit($json->message);
  23. //echo count($json->tables);
  24. ?>
  25. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  26. <html>
  27. <head>
  28. <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
  29. <meta http-equiv="Pragma" content="no-cache" />
  30. <meta http-equiv="Expires" content="0" />
  31. <link rel="stylesheet" href="css/get_info.css">
  32. </head>
  33. <body>
  34. <?php
  35. foreach ($json->tables as $table) :
  36. if ($table->table_row == null) continue;
  37. ?>
  38. <div style="text-align: center;"><span class='clh2'>Кабардино-Балкарский государственный университет им. Х.М. Бербекова</span>
  39. <span class='clh1'>ПРОТОКОЛ</span>
  40. <span class='clh2'>текущей успеваемости студента по балльно-рейтинговой системе</span>
  41. </div>
  42. <span class='clh3'><?= $table->faculty ?></span>
  43. <span class='clh3'><b><?= $table->specialty ?></b></span>
  44. <span class='clh3'>
  45. <?= $table->course ?> курс <?= $table->group ?> группа <?= $table->sem ?> семестр <?= $table->teacher_year ?> учебный год
  46. </span>
  47. <span class='clh3'><b><?= $json->fio ?></b></span>
  48. <table width=100% border=0>
  49. <tr>
  50. <td>
  51. <table width=100% class='clTableBold'>
  52. <tr>
  53. <td class='clTableCols' rowspan=2 align=center>№</td>
  54. <td class='clTableCols' style='width: 400px' rowspan=2 align=center>Дисциплина</td>
  55. <td class='clTableCols' style='width: 400px' rowspan=2 align=center>Преподаватель</td>
  56. <td class='clTableCols' colspan=5 align=center>1 контрольная точка</td>
  57. <td class='clTableCols' colspan=5 align=center>2 контрольная точка</td>
  58. <td class='clTableCols' colspan=5 align=center>3 контрольная точка</td>
  59. <td class='clTableCols' rowspan=2 align=center>Сумма<br>итог.</td>
  60. <td class='clTableCols' rowspan=2 align=center>Прош.<br>сем.</td>
  61. <td class='clTableCols' rowspan=2 align=center>Зачет</td>
  62. <td class='clTableCols' rowspan=2 align=center>Экзам.</td>
  63. <td class='clTableCols' rowspan=2 align=center>Отраб.</td>
  64. <td class='clTableCols' rowspan=2 align=center>Пересдача</td>
  65. <td class='clTableCols' rowspan=2 align=center>Общий<br>итог.</td>
  66. <td class='clTableCols' rowspan=2 align=center>Оценка</td>
  67. </tr>
  68. <tr>
  69. <td class='clTableCols' align=center>П</td>
  70. <td class='clTableCols' align=center>К</td>
  71. <td class='clTableCols' align=center>Т</td>
  72. <td class='clTableCols' align=center>И</td>
  73. <td class='clTableCols' align=center>∑</td>
  74. <td class='clTableCols' align=center>П</td>
  75. <td class='clTableCols' align=center>К</td>
  76. <td class='clTableCols' align=center>Т</td>
  77. <td class='clTableCols' align=center>И</td>
  78. <td class='clTableCols' align=center>∑</td>
  79. <td class='clTableCols' align=center>П</td>
  80. <td class='clTableCols' align=center>К</td>
  81. <td class='clTableCols' align=center>Т</td>
  82. <td class='clTableCols' align=center>И</td>
  83. <td class='clTableCols' align=center>∑</td>
  84. </tr>
  85. <?php
  86. $index = 0;
  87. foreach ($table->table_row as $rating) :
  88. ?>
  89. <tr class=''>
  90. <td class='cltd' align=center><?= $rating->index ?></td>
  91. <td class='cltd'>
  92. <?= $rating->uplan_name ?> <br /><b><?= $rating->final ?></b>
  93. </td>
  94. <td class='cltd'><?= $rating->teacher ?></td>
  95. <td class='cltd' align=center><b><?= $rating->first_point->p ?></b></td>
  96. <td class='cltd' align=center><b><?= $rating->first_point->k ?></b></td>
  97. <td class='cltd' align=center><b><?= $rating->first_point->t ?></b></td>
  98. <td class='cltd' align=center><b><?= $rating->first_point->i ?></b></td>
  99. <td class='cltdb' align=center><b><?= $rating->first_point->summ ?></b></td>
  100. <td class='cltd' align=center><b><?= $rating->second_point->p ?></b></td>
  101. <td class='cltd' align=center><b><?= $rating->second_point->k ?></b></td>
  102. <td class='cltd' align=center><b><?= $rating->second_point->t ?></b></td>
  103. <td class='cltd' align=center><b><?= $rating->second_point->i ?></b></td>
  104. <td class='cltdb' align=center><b><?= $rating->second_point->summ ?></b></td>
  105. <td class='cltd' align=center><b><?= $rating->third_point->p ?></b></td>
  106. <td class='cltd' align=center><b><?= $rating->third_point->k ?></b></td>
  107. <td class='cltd' align=center><b><?= $rating->third_point->t ?></b></td>
  108. <td class='cltd' align=center><b><?= $rating->third_point->i ?></b></td>
  109. <td class='cltdb' align=center><b><?= $rating->third_point->summ ?></b></td>
  110. <td class='cltdb' align=center><b><?= $rating->summ_point ?></b></td>
  111. <td class='cltdb' align=center><b><?= $rating->bps ?></b></td>
  112. <td class='cltdb' align=center><b><?= $rating->offset ?></b></td>
  113. <td class='cltd' align=center><b><?= $rating->exam ?></b></td>
  114. <td class='cltdb' align=center><b><?= $rating->working_off ?></b></td>
  115. <td class='cltdb' align=center><?= $rating->rb_bo ?></td>
  116. <td class='cltdb' align=center><?= $rating->total ?></td>
  117. <td class='cltdb' align=center><?= $rating->total_str ?></td>
  118. </tr>
  119. <?php endforeach ?>
  120. </table>
  121. </td>
  122. </tr>
  123. </table>
  124. <span class='clh4'>
  125. П - посещаемость <br /> К - коллоквиум <br /> Т - тестирование <br /> И - иные формы контроля<br>
  126. </span>
  127. <div class="page-break"></div>
  128. <?php endforeach ?>
  129. </body>
  130. </html>