No bug selected..."; header("Refresh: 2; URL=$_SERVER[HTTP_REFERER]"); goto footer; } $conn = new PDO($config['db']['dsn'], $config['db']['username'], $config['db']['password']); $query = $conn->prepare("SELECT title, description, users.username AS submitter FROM bugs JOIN users ON bugs.author = users.id WHERE bugs.id=:bug_id"); $query->bindParam(':bug_id', $_GET['id']); $query->execute(); $result = $query->fetch(); $markdown = new Parsedown(); echo "
$result[title]
"; echo "Submitted by $result[submitter]
"; echo '' . $markdown->text($result['description']) . '
'; echo "Title | Description | Submitted by | $row[title] | " . truncate($row['description']) . " | $row[user] | \n"; } ?>
---|