query('SELECT * FROM pastes WHERE uid="'.$uid.'"'); if($result = $stmt->fetch(PDO::FETCH_ASSOC)){ $conn = null; if($result["exposure"]==2 && isset($_COOKIE["pp_sid"]) && isset($_COOKIE["pp_skey"]) && $result["owner"]!=GetUsersIDBySession($_COOKIE["pp_sid"],$_COOKIE["pp_skey"])){ echo "

This paste is private

"; die(); } echo "

".htmlspecialchars($result["title"], ENT_QUOTES, 'UTF-8')."

"; // $owner = GetUserByID($result["owner"]); echo "
"; if($owner[1] == -1) echo "Posted by: Guest"; else echo "Posted by: ".htmlspecialchars($owner[1]).""; echo ", at ".date('Y-m-d',$result["created"])."
"; // echo "
";
		echo htmlspecialchars($result["text"], ENT_QUOTES, 'UTF-8')."
"; echo ""; echo ""; } else echo "Paste does not exist"; $conn = null; } else echo "Error: id not set"; ?>