From d86eb10d1f07340cd7e3497a3554279ff273de6a Mon Sep 17 00:00:00 2001 From: alopexc0de Date: Thu, 26 Jun 2014 20:38:35 -0400 Subject: [PATCH] Move database connection to independant file --- Website/index.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Website/index.php b/Website/index.php index ed935dd..5ce5e43 100644 --- a/Website/index.php +++ b/Website/index.php @@ -22,8 +22,7 @@ exit 13 - Shortener About redirection */ - $shortdb = new mysqli('localhost', 'short', 'password', 'short'); // Connect to link shortener DB - if($shortdb->connect_errno > 0) die('Unable to connect to database [' . $shortdb->connect_error . '] - Check dbsettings.php'); + require('Include/PHP/db.php'); // This has been depreciated. Still here for backwards compatibility with existing links if(!empty($_GET['l'])){