added README, refactored Database.php
authorSven Hecht <sven@sven-laptop.(none)>
Wed, 24 Jun 2009 20:35:16 +0000 (22:35 +0200)
committerSven Hecht <sven@sven-laptop.(none)>
Wed, 24 Jun 2009 20:35:16 +0000 (22:35 +0200)
web/php/Database.php

index 19e5abe..809372f 100644 (file)
@@ -2,10 +2,14 @@
        
        class DataBase
        {
+               private $m_Username = "lseed";
+               private $m_Password = "GCp:rtAaN8nwTFMP";
+               private $m_Server = "localhost";
+               private $m_Database = "lseed";
                public $m_Connection;
 
                public function __construct() {
-                       $this->m_Connection = @new mysqli( 'localhost', 'lseed', 'GCp:rtAaN8nwTFMP', 'lseed' );
+                       $this->m_Connection = @new mysqli( $this->m_Server, $this->m_Username, $this->m_Password, $this->m_Database );
                        if (mysqli_connect_errno() != 0) {
                                die( "Argh what did you do?->SERVERERR=0, ".mysqli_connect_error());
                        }