A better way to make a connection to the database

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

No files matched your search

+1
View File
@@ -1,6 +1,7 @@
<?php
include_once "config/config.php";
function RemoveExpiredPastes(){
$conn = GetConnectionToDB();
$time = time();
$stmt = $conn->prepare("DELETE from `pastes` where `expire`<:time and `expire`>0");
$stmt->bindValue(':time', $time);