summaryrefslogtreecommitdiff
path: root/inc/database.php
diff options
context:
space:
mode:
Diffstat (limited to 'inc/database.php')
-rw-r--r--inc/database.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/inc/database.php b/inc/database.php
index 21fabe71..88ca1c0d 100644
--- a/inc/database.php
+++ b/inc/database.php
@@ -1,4 +1,9 @@
<?php
+ if($_SERVER['SCRIPT_FILENAME'] == str_replace('\\', '/', __FILE__)) {
+ // You cannot request this file directly.
+ header('Location: ../', true, 302);
+ exit;
+ }
function sql_open() {
global $pdo, $config;