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
[Help] Xampp Issue
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="Lionches" data-source="post: 139136" data-attributes="member: 11637"><p>Change to this:</p><p>[PHP]<?php</p><p>/*=======================================================================</p><p>| UberCMS - Advanced Website and Content Management System for uberEmu</p><p>| #######################################################################</p><p>| Copyright (c) 2010, Roy 'Meth0d'</p><p>| http://www.meth0d.org</p><p>| #######################################################################</p><p>| This program is free software: you can redistribute it and/or modify</p><p>| it under the terms of the GNU General Public License as published by</p><p>| the Free Software Foundation, either version 3 of the License, or</p><p>| (at your option) any later version.</p><p>| #######################################################################</p><p>| This program is distributed in the hope that it will be useful,</p><p>| but WITHOUT ANY WARRANTY; without even the implied warranty of</p><p>| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</p><p>| GNU General Public License for more details.</p><p>\======================================================================*/</p><p> </p><p>class MySQL</p><p>{</p><p>private $connected = false;</p><p>private $hostname = "localhost";</p><p>private $username = "root";</p><p>private $password = "bottomline";</p><p>private $database = "uber";</p><p>private $link = "192.168.1.6;</p><p> </p><p>public function MySQL($host, $user, $pass, $db)</p><p>{</p><p>$this->connected = false;</p><p>$this->hostname = $localhost;</p><p>$this->username = $root;</p><p>$this->password = $bottomline;</p><p>$this->database = $uber;</p><p>}</p><p> </p><p>public function IsConnected()</p><p>{</p><p>if ($this->connected)</p><p>{</p><p>return true;</p><p>}</p><p> </p><p>return false;</p><p>}</p><p> </p><p>public function Connect()</p><p>{</p><p>$this->192.168.1.6 = mysql_connect($this->localhost, $this->root, $this->bottomline) or $this->error(mysql_error());</p><p>mysql_select_db($this->uber, $this->192.168.1.6) or $this->error(mysql_error());</p><p> </p><p>$this->connected = true;</p><p>}</p><p> </p><p>public function Disconnect()</p><p>{</p><p>if($this->connected)</p><p>{</p><p>@mysql_close($this->192.168.1.6) or $this->error("could not close conn");</p><p>$this->connected = false;</p><p>}</p><p>}</p><p> </p><p>public function DoQuery($query)</p><p>{</p><p>$resultset = @mysql_query($query, $this->192.168.1.6) or $this->error(mysql_error());</p><p>return $resultset;</p><p>}</p><p> </p><p>public function Evaluate($resultset)</p><p>{</p><p>return @mysql_result($resultset, 0);</p><p>}</p><p> </p><p>public function Error($errorString)</p><p>{</p><p>global $core;</p><p> </p><p>$core->systemError('Database Error', $errorString);</p><p>}</p><p> </p><p>public function __destruct()</p><p>{</p><p>$this->disconnect();</p><p>}</p><p>}</p><p> </p><p>?>[/PHP]</p><p>Worked?</p></blockquote><p></p>
[QUOTE="Lionches, post: 139136, member: 11637"] Change to this: [PHP]<?php /*======================================================================= | UberCMS - Advanced Website and Content Management System for uberEmu | ####################################################################### | Copyright (c) 2010, Roy 'Meth0d' | http://www.meth0d.org | ####################################################################### | This program is free software: you can redistribute it and/or modify | it under the terms of the GNU General Public License as published by | the Free Software Foundation, either version 3 of the License, or | (at your option) any later version. | ####################################################################### | This program is distributed in the hope that it will be useful, | but WITHOUT ANY WARRANTY; without even the implied warranty of | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | GNU General Public License for more details. \======================================================================*/ class MySQL { private $connected = false; private $hostname = "localhost"; private $username = "root"; private $password = "bottomline"; private $database = "uber"; private $link = "192.168.1.6; public function MySQL($host, $user, $pass, $db) { $this->connected = false; $this->hostname = $localhost; $this->username = $root; $this->password = $bottomline; $this->database = $uber; } public function IsConnected() { if ($this->connected) { return true; } return false; } public function Connect() { $this->192.168.1.6 = mysql_connect($this->localhost, $this->root, $this->bottomline) or $this->error(mysql_error()); mysql_select_db($this->uber, $this->192.168.1.6) or $this->error(mysql_error()); $this->connected = true; } public function Disconnect() { if($this->connected) { @mysql_close($this->192.168.1.6) or $this->error("could not close conn"); $this->connected = false; } } public function DoQuery($query) { $resultset = @mysql_query($query, $this->192.168.1.6) or $this->error(mysql_error()); return $resultset; } public function Evaluate($resultset) { return @mysql_result($resultset, 0); } public function Error($errorString) { global $core; $core->systemError('Database Error', $errorString); } public function __destruct() { $this->disconnect(); } } ?>[/PHP] Worked? [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
[Help] Xampp Issue
Top