Project

General

Profile

« Previous | Next » 

Revision 1682

Added by darkviper over 12 years ago

some little corrections ModLanguage/Database/initialize.php

View differences:

Database.php
31 31

  
32 32
class Database {
33 33

  
34
//	$sdb = 'mysql://user:password@demo.de:3604/datenbank';
34
//	$sdb = 'mysql://user:password@demo.de:3306/datenbank';
35 35

  
36 36
	private $_db_handle = null; // readonly from outside
37 37
	private $_scheme    = 'mysql';
38 38
	private $_hostname  = 'localhost';
39 39
	private $_username  = '';
40 40
	private $_password  = '';
41
	private $_hostport  = '3406';
41
	private $_hostport  = '3306';
42 42
	private $_db_name   = '';
43 43

  
44 44
	private $connected  = false;
......
61 61
			$this->_hostport = $this->_hostport == '3306' ? '' : ':'.$this->_hostport;
62 62
			$this->_db_name  = ltrim(isset($aIni['path']) ? $aIni['path'] : '', '/\\');
63 63
		}else {
64
			$this->_hostname = DB_HOST;
65
			$this->_username = DB_USERNAME;
66
			$this->_password = DB_PASSWORD;
67
			$this->_hostport = '';
68
			$this->_db_name  = DB_NAME;
64
			throw new RuntimeException('Missing parameter: unable to connect database');
69 65
		}
70 66
		// Connect to database
71 67
		$this->connect();

Also available in: Unified diff