<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\ResultProcessing\Controller\ResultProcessingController as ResultProcessing; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $class = $_GET["class"]; $subject = $_GET["subject"]; $view = new RegisterStudent(); $viewb = new ResultProcessing(); $fields = $view->getTableFields(); $students = $viewb->getStudentsBySubject($subject, $class); echo "<input type='hidden' id='CURRENTSUBJECT' value='" . $subject . "' name='" . $viewb->getSubjectName($subject)["subject_name"] . "'/>"; echo "<input type='hidden' id='CURRENTCLASS' value='" . $class . "' name='" . $viewb->getClassName($class)["class_name"] . "'/>"; ?> <h6 class='pull-right' id="currentInfo"></h6> <table id="example1" class="table table-bordered table-striped"> <thead> <tr> <?php foreach ($fields as $field) { $name = $field["Name"]; echo "<th>{$name}</th>"; } ?> </tr> </thead> <tbody> <?php foreach ($students as $student) { $info = $view->getStudentInfo($student); if (isset($info[0])) {
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $view = new RegisterStudent(); $fields = $view->getTableFields(); $students = $view->getStudents(); ?> <section class="content"> <div class="row"> <div class="col-xs-12"> <div class="box"> <div class="box-header"> <h3 class="box-title">You Can Use The Search Form To Filter Data On This Page</h3> </div><!-- /.box-header --> <div class="box-body"> <table id="example1" class="table table-bordered table-striped"> <thead> <tr> <?php foreach ($fields as $field) { $name = $field["Name"]; echo "<th>{$name}</th>"; } ?> </tr> </thead> <tbody> <?php foreach ($students as $student) { echo "<tr>";
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); if (count($_POST) < 1) { $id = 0; $value = ""; $newvalue = ""; } else { $id = $_POST["id"]; $value = str_replace("-", " ", $_POST["value"]); $newvalue = $_POST["newvalue"]; } $v = $rs->valueUpdate($id, $value, $newvalue); print_r($v); //print_r(array($id, $value, $newvalue));
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); $id = $_GET["id"]; $v = $rs->deleteStudentFromClass($id); echo json_encode($v);
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); $id = $_GET["id"]; $subject = $_GET["subject"]; $class = $_GET["class"]; $v = $rs->deleteStudentFromSubject($id, $subject, $class); echo json_encode($v);
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $view = new RegisterStudent(); $classes = $view->getClasses(); $subjects = $view->getSubjects(); ?> <section class="content"> <div class="row"> <div class="col-xs-12"> <div class="box"> <div class="box-header"> <h3 class="box-title">Select A Class And A Subject To Continue</h3> </div><!-- /.box-header --> <div class="box-body"> <div class='form-group col-md-6'> <label>Select A Class</label> <select class="form-control select2" data-placeholder="" style="width: 100%;" name="class" id="selectclassname"> <?php foreach ($classes as $class) { $id = $class[0]; $name = $class[1]; echo "<option value='" . $id . "'>" . $name . "</option>"; } ?> </select> </div> <div class='form-group col-md-6'> <label>Select A Subject</label> <select class="form-control select2" data-placeholder="" style="width: 100%;" name="class" id="selectsubjectname">
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); $result = $rs->getStudents("'1'");
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); $id = $_GET["id"]; $v = $rs->deleteStudent($id); echo json_encode($v); //print_r(array($id, $value, $newvalue));
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $rs = new RegisterStudent(); $postdata = $_POST; $data = array(); foreach ($postdata as $key => $value) { $data[] = array($value, false); } $b = $rs->insertNewStudent($data);
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $view = new RegisterStudent(); $classes = $view->getClasses(); ?> <section class="content"> <div class="row"> <div class="col-xs-12"> <div class="box"> <div class="box-header"> <h3 class="box-title">Select A Class To Edit The Students In That Class</h3> </div><!-- /.box-header --> <div class="box-body"> <div class='form-group'> <label>Select A Class</label> <select class="form-control select2" data-placeholder="" style="width: 100%;" name="class" id="selectclassname"> <option></option> <?php foreach ($classes as $class) { $id = $class[0]; $name = $class[1]; echo "<option value='" . $id . "'>" . $name . "</option>"; } ?> </select> </div> <div id="con"></div> </div><!-- /.box-body --> </div><!-- /.box -->
<?php require $_SERVER["DOCUMENT_ROOT"] . '/vendor/autoload.php'; use SMS\App\Modules\RegisterStudent\Controller\RegisterStudentController as RegisterStudent; $view = new RegisterStudent(); $fields = $view->getTableFields(); ?> <div class="box box-default"> <div class="box-header with-border"> <h3 class="box-title">Student Registration Form <small>Use The Slider Below To Change The Size Of The Form To Suit You</small></h3> <input class="bar" type="range" id="rangeinput" value="4" min="2" max="12"/> <div class="box-tools pull-right"> <button class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button> <button class="btn btn-box-tool" data-widget="remove"><i class="fa fa-remove"></i></button> </div> </div><!-- /.box-header --> <form id="StudentForm"> <div class="box-body"> <div class="row"> <?php foreach ($fields as $field) { $name = $field["Name"]; $type = $field["Type"]; echo "<div class='col-md-4 FORMSIZE'><div class='form-group'><label>{$name}</label>"; $inputtype = $view->predictInputType($field); if ($inputtype == "SELECT") { $select_elements = $view->loadSelectElements($name); echo "<select class='form-control select2 NEWSTUDENTFIELD' style='width:100%;' data-id='{$name}' name='{$name}'>"; foreach ($select_elements as $element) { $value = $element[str_replace(" ", "_", strtolower($name))]; echo "<option value='" . $element["id"] . "'>" . $value . "</option>";