mirror of
https://github.com/pikami/palm-paste.git
synced 2025-12-19 08:49:49 +00:00
A better way to make a connection to the database
This commit is contained in:
@@ -6,7 +6,8 @@
|
||||
$uid = $_GET["page"];
|
||||
echo '<script type="text/javascript" src="js/SyntaxHighlighter/shCore.js"></script>';
|
||||
//
|
||||
include "config/config.php";
|
||||
include_once "config/config.php";
|
||||
$conn = GetConnectionToDB();
|
||||
$stmt = $conn->query('SELECT highlight FROM pastes WHERE uid="'.$uid.'"');
|
||||
if($result = $stmt->fetch(PDO::FETCH_ASSOC)){
|
||||
$conn = null;
|
||||
|
||||
Reference in New Issue
Block a user