prepare("INSERT INTO pastes (title,text) VALUES (:tit, :txt)"); $stmt->bindParam(':tit', $title); $stmt->bindParam(':txt', $text); $stmt->execute(); $conn = null; //close connection to database } } echo "FIN!"; $conn = null; ?>