Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
Installation of Radipanel
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="ColinC" data-source="post: 453739" data-attributes="member: 88783"><p><?php</p><p> class Database {</p><p></p><p> /* </p><p> * Constructor - connects to database.</p><p> * @global $params - core parameters from glob.php</p><p> */</p><p> public function __construct() {</p><p></p><p> global $params;</p><p> $this->connection = mysql_connect( $params['db']['localhost'], $params['db']['zimplera_delta'], $params['db']['***password****'] );</p><p> mysql_select_db( $params['db']['zimplera_delta'] );</p><p></p><p> }</p><p> </p><p> /*</p><p> * Query - executes a MySQL query.</p><p> * @param $string - required. the input SQL string.</p><p> * [USER=59761]@reTurn[/USER] $q - the resulting query.</p><p> */</p><p> public function query( $string ) {</p><p></p><p> $q = mysql_query( $string );</p><p></p><p> if( !$q ) {</p><p></p><p> echo "<div style=\"font-family: tahoma; font-size: 11px; width: 400px; margin: auto;\">";</p><p> echo "<big><center><strong>MySQL Error:</strong></center></big>";</p><p> echo mysql_error();</p><p> echo "</div>";</p><p></p><p> die();</p><p>[automerge]1570968281[/automerge]</p><p>That is from db.inc.php</p></blockquote><p></p>
[QUOTE="ColinC, post: 453739, member: 88783"] <?php class Database { /* * Constructor - connects to database. * @global $params - core parameters from glob.php */ public function __construct() { global $params; $this->connection = mysql_connect( $params['db']['localhost'], $params['db']['zimplera_delta'], $params['db']['***password****'] ); mysql_select_db( $params['db']['zimplera_delta'] ); } /* * Query - executes a MySQL query. * @param $string - required. the input SQL string. * [USER=59761]@reTurn[/USER] $q - the resulting query. */ public function query( $string ) { $q = mysql_query( $string ); if( !$q ) { echo "<div style=\"font-family: tahoma; font-size: 11px; width: 400px; margin: auto;\">"; echo "<big><center><strong>MySQL Error:</strong></center></big>"; echo mysql_error(); echo "</div>"; die(); [automerge]1570968281[/automerge] That is from db.inc.php [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
Installation of Radipanel
Top