A better way to make a connection to the database

This commit is contained in:
pikami
2016-06-16 15:33:16 +00:00
parent 4c1f18c593
commit e9ccb5c919
11 changed files with 48 additions and 32 deletions

View File

@@ -2,8 +2,9 @@
<div class="panel panel-default">
<div class="panel-body">
<?php
include "config/config.php";
include_once "config/config.php";
include_once "includes/user.php";
$conn = GetConnectionToDB();
if(GetUsersIDBySession($_COOKIE["pp_sid"],$_COOKIE["pp_skey"]) == -1){
printf('<h2>You must be loged in to see your pastes!</h2>');
$conn = null;