Show sourcecode
The following files exists in this folder. Click to view.
admin.php
createQuiz.php
createadmin.php
logIn.php
myStats.php
playquiz.php
result.php
scoreboard.php
signIn.php
start.php
startsida.php
stats.php
style.css
tables.php
update.php
startsida.php
30 lines UTF-8 Windows (CRLF)
<?php
/** @var PDO $dbconn */
include ("start.php");
?>
<!-- Länkar för scoreboard sida för att se sina egna resultat -->
<a href="scoreboard.php">Scoreboard</a> <br>
<a href="myStats.php">Mina resultat</a> <br>
<a href="stats.php">Statistik</a>
<!-- Lista av alla quiz -->
<ol><strong>Quiz</strong>
<?php
$sql = "SELECT * FROM quizes";
$stmt = $dbconn->prepare($sql);
$data = array();
$stmt->execute($data);
while ($res = $stmt->fetch(PDO::FETCH_ASSOC)) {
$id = $res["id"];
$quizname = $res["quizname"];
echo "<li><a target='_blank' href='playquiz.php?quizId=$id'>$quizname</a></li>";
}
?>
</ol>
</body>
</html>