curso.php 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. <?php
  2. require 'functions.php';
  3. $cursos = listarCursos();
  4. $alunos = listarAlunos($_GET['curso']);
  5. $exercicios = listarExercicios($_GET['curso']);
  6. ?>
  7. <!doctype html>
  8. <html lang="en">
  9. <head>
  10. <meta charset="utf-8" />
  11. <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
  12. <title>ivprog_log_analysis</title>
  13. <link href="css/bootstrap.min.css" rel="stylesheet" />
  14. <link href="css/style.css" rel="stylesheet" />
  15. </head>
  16. <body>
  17. <nav class="navbar navbar-expand-md navbar-dark fixed-top" style="background-color: #03396c;">
  18. <b><a class="navbar-brand" href="./">ivprog_log_analysis - Ambiente de análise dos logs do iVProgH</a></b>
  19. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarsExampleDefault" aria-controls="navbarsExampleDefault" aria-expanded="false" aria-label="Toggle navigation">
  20. <span class="navbar-toggler-icon"></span>
  21. </button>
  22. <div class="collapse navbar-collapse" id="navbarsExampleDefault">
  23. <ul class="navbar-nav mr-auto">
  24. <li class="nav-item active">
  25. <a class="nav-link" href="./" title=""></a>
  26. </li>
  27. </ul>
  28. </div>
  29. </nav>
  30. <main role="main">
  31. <div class="jumbotron ivprogh-desc">
  32. <div class="container">
  33. <?= instrucoes() ?>
  34. </div>
  35. </div>
  36. <div class="container ivprog-container" style="padding: 3em; margin-top: 3em;">
  37. <form action="process.php" method="get" novalidate>
  38. <div class="form-group row">
  39. <label for="inputname" class="col-sm-2 col-form-label">Curso:</label>
  40. <div class="col-sm-10">
  41. <select class="form-control" id="inputname" name="curso">
  42. <?php
  43. for ($i = 0; $i < count($cursos); $i++) {
  44. echo "<option" . ($cursos[$i] == $_GET['curso']?" selected":"") . ">" . $cursos[$i] . "</option>";
  45. }
  46. ?>
  47. </select>
  48. </div>
  49. </div>
  50. <div class="form-group row">
  51. <label for="inputaluno" class="col-sm-2 col-form-label">Aluno:</label>
  52. <div class="col-sm-10">
  53. <select class="form-control" id="inputaluno" name="aluno">
  54. <option>Todos</option>
  55. <?php
  56. foreach ($alunos as $aluno) {
  57. echo "<option value='$aluno'>$aluno</option>";
  58. }
  59. ?>
  60. </select>
  61. </div>
  62. </div>
  63. <div class="form-group row">
  64. <label for="inputexercicio" class="col-sm-2 col-form-label">Exercício:</label>
  65. <div class="col-sm-10">
  66. <select class="form-control" id="inputexercicio" name="exercicio">
  67. <option value="Todos">Todos</option>
  68. <?php
  69. foreach ($exercicios as $exercicio) {
  70. echo "<option value='$exercicio'>$exercicio</option>";
  71. }
  72. ?>
  73. </select>
  74. </div>
  75. </div>
  76. <div class="form-group row">
  77. <div class="offset-sm-2 col-sm-10">
  78. <button type="button" class="btn btn-secondary" onclick="window.history.back();">Voltar</button>
  79. <button type="submit" class="btn btn-primary">Continuar</button>
  80. <span class="reported" style="color: green; font-size: 120%;"></span>
  81. <span class="error" style="color: red; font-size: 120%;"></span>
  82. </div>
  83. </div>
  84. </form>
  85. </div>
  86. <div>
  87. </div>
  88. </main>
  89. <footer class="container text-center">
  90. <a href="http://www.ime.usp.br/line">iVProgH</a> |
  91. <a href="http://www.ime.usp.br/line">LInE</a> |
  92. <a href="http://www.matematica.br">iM&aacute;tica</a>
  93. </footer>
  94. <script src="./js/jquery.min.js"></script>
  95. <script src="./js/bootstrap.bundle.min.js"></script>
  96. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/octicons/3.5.0/octicons.min.css">
  97. </body>
  98. </html>