<h4><a href="admin.php?p=10&c=2"><span class="glyphicon glyphicon-plus"></span> New Question</a></h4> </div> </h1> <div class="table-responsiv"> <table cellpadding="0" cellspacing="0" border="0" class="datatable-1 table table-bordered table-striped display"> <thead> <tr> <th>#</th> <th>Question</th> <th>Point</th> <th>Action</th> </tr> </thead> <tbody> <?php foreach (QuestionCtrl::getQuestionsByCategory(2) as $key => $q) { ?> <tr> <td style="text-align: center"><?php echo $key + 1; ?> </td> <td><?php echo $q->getShortTitle(); ?> </td> <td><?php echo $q->getPoint(); ?> </td> <td style="text-align: center">
<?php require_once './controller/QuestionCtrl.php'; $c = 1; if (isset($_GET['c']) && $_GET['c'] != '') { $c = $_GET['c']; if ($c != 1 && $c != 2) { $c = 1; } } $question_arr = QuestionCtrl::getQuestionsByCategory($c); function getKText($opt) { switch ($opt) { case 0: return 'A'; break; case 1: return 'B'; break; case 2: return 'C'; break; case 3: return 'D'; break; } } $type = 'Pre-Test'; if ($c == 2) { $type = 'Post-Test';