prepare('SELECT * FROM pastes WHERE uid=:uid'); $stmt->bindParam(':uid', $paste); $stmt->execute(); if ($stmt->rowCount() > 0) { while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) { if ($row['owner'] === $uid) { include "views/_new-paste.php"; } else { $conn = null; echo '

You are not the owner of the paste ' . $row["uid"] . '

'; echo ''; die(); } } } else { $conn = null; echo '

The paste ' . $row["uid"] . ' does not exist

'; echo ''; } $conn = null; } ?>