Hi guys! Its been a long time now.. But, here is a small release from me ;) However, if you want to change your hotel name from hk, then you shall add this!
Go in global.php hit ctrl + h
Search for:
PHP Code:
$cron->Execute();
Under that add this:
PHP Code:
// ############################################################################
// Load Settings
$query = dbquery("SELECT value,name FROM settings ORDER BY title ASC");
while($setting = mysql_fetch_array($query))
{
$setting['value'] = str_replace("\"", "\\\"", $setting['value']);
$settings[$setting['name']] = $setting['value'];
}
mysql_free_result($query);
$core->setting = &$settings;
define("SHORTNAME", $settings['hotel_shortname']);
define("HOTELNAME", $settings['hotel_name']);
One step done.
Okay, now go to /inc/class.tpl.php
Search for
PHP Code:
$this->SetParam('www', WWW);
Add under that this:
PHP Code:
$this->SetParam('shortname', SHORTNAME);
$this->SetParam('hotelname', HOTELNAME);
Now go to /inc/tpl/head-init.tpl. Open it and search for Replace the whole line with:
PHP Code:
<title>%shortname%: %page_title%</title>
I think that is it, its preatty useless really, but good for noobs! Oh wait, i forgot to add the MySQL!
PHP Code:
--
-- Table structure for table `settings`
--
CREATE TABLE IF NOT EXISTS `settings` (
`title` int(255) NOT NULL,
`value` varchar(255) NOT NULL,
`name` varchar(2553) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
--
-- Dumping data for table `settings`
--
INSERT INTO `settings` (`title`, `value`, `name`) VALUES
(1, 'Habbo', 'hotel_shortname'),
(3, 'Habbo Hotel', 'hotel_name');
-- --------------------------------------------------------
Tell me if it not are working!
Update:
Open global.php, search for:
PHP Code:
$core->setting = &$settings;
Add under it:
PHP Code:
define("WWW", $settings['hotel_path']);
New sql:
PHP Code:
INSERT INTO `settings` (`title`, `value`, `name`) VALUES
(2, 'http://localhost', 'hotel_path');
Remove from inc/inc.config.php
PHP Code:
$config['Site']['www'] = "http://localhost";
Credits: Tweeney 90%
Me: Fixing it up.