about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--central/trunk/common.php13
-rw-r--r--central/trunk/db.php5
-rw-r--r--central/trunk/index.php8
3 files changed, 25 insertions, 1 deletions
diff --git a/central/trunk/common.php b/central/trunk/common.php new file mode 100644 index 0000000..573ce15 --- /dev/null +++ b/central/trunk/common.php
@@ -0,0 +1,13 @@
1<?php
2
3/* InstaDisc Server - A Four Island Project */
4
5include('db.php');
6
7$getconfig = "SELECT * FROM config";
8$getconfig2 = mysql_query($getconfig);
9$config = mysql_fetch_array($getconfig2);
10
11include('header.php');
12
13?>
diff --git a/central/trunk/db.php b/central/trunk/db.php index 61d9bc4..c492722 100644 --- a/central/trunk/db.php +++ b/central/trunk/db.php
@@ -8,6 +8,11 @@ if (!file_exists('config.php'))
8 exit; 8 exit;
9} 9}
10 10
11if (file_exists('install.php'))
12{
13 die('Excuse me, but you need to delete install.php before you can use this as leaving install.php there is a biiiig security hole.');
14}
15
11include('config.php'); 16include('config.php');
12 17
13mysql_connect($dbhost, $dbuser, $dbpass); 18mysql_connect($dbhost, $dbuser, $dbpass);
diff --git a/central/trunk/index.php b/central/trunk/index.php index 31d1af7..6ba21ab 100644 --- a/central/trunk/index.php +++ b/central/trunk/index.php
@@ -2,6 +2,12 @@
2 2
3/* InstaDisc Server - A Four Island Project */ 3/* InstaDisc Server - A Four Island Project */
4 4
5include('db.php'); 5include('common.php');
6
7?>Welcome to the <?php echo($config['title']); ?> InstaDisc Server!<P><?php
8
9echo($config['text']);
10
11include('footer.php');
6 12
7?> 13?>