<link rel="stylesheet" href="main.css" type="text/css" /> <script src='../js/jq.js' type='text/javascript'></script> <script src='function.js' type='text/javascript' ></script> </head> <body> <?php include "../header.php"; ?> <div id="sidebar"> <a href="../index.php">Main</a><br> <?php include_once "../class.inc.php"; if (isset($_GET['id'])) { $cbt = new CBT(); $id = $cbt->clean($_GET['id']); echo '<script type="text/javascript"> var MAXNUM =', $cbt->totalQuestions($id), '; </script>'; for ($i = 1; $i <= $cbt->totalQuestions($id); $i++) { echo '<a href="#" onclick="qShow(', $i, ')" class="ql-', $i, '">', $i, '</a><br>'; } echo '<a href="#" onclick="qShow(', $i, ')" class="ql-', $i, '">Finish</a><br>'; echo '<br></div>'; // sidebar echo '<div id="center"><form method="POST">'; $i = 1; $questions = $cbt->getQuestions($id); shuffle($questions); // to randomize the order of questions foreach ($questions as $ques) {