Newbie Spellweaver
- Joined
- Dec 25, 2015
- Messages
- 56
- Reaction score
- 27
MinCMS is a 2017 RevCMS edit to make it better and faster.
There's not much RevCMS code left
Github:
Bugs
- admin (housekeeping) not working (don't know why)
gif of base theme
v0.2 will have many changes
Emulator and Database compatibility: Arcturus
What has changed so far?
Code Snippets
- config.php
- engine.php
How to make your own theme?
Credits
- MinCMS -> dimaklt
- RevCMS -> Kryptos
There's not much RevCMS code left
Github:
You must be registered to see links
Bugs
- admin (housekeeping) not working (don't know why)
gif of base theme
v0.2 will have many changes
Emulator and Database compatibility: Arcturus
What has changed so far?
Code:
- config moved to root
- language support added
- interfaces removed
- class.forms.php removed
- MySQLi instead of MySQL
- beautiful URLs
- folder names changed
- ase -> admin
- app -> src
- template -> view
- skins -> views
- hk -> admin
- file names changed
- class.*.php -> *.php
- class.template.php -> view.php
Code Snippets
- config.php
Code:
<?php
if(!defined('IN_INDEX')) { die(header('location: ./404')); }
$config = (object) array(
'in_dev' => true,
'view' => 'hobba',
'lang' => 'de',
'mysql' => (object) array(
'hostname' => 'localhost',
'username' => 'root',
'password' => '',
'database' => 'habbo',
'port' => 3306
),
'hotel' => (object) array(
'url' => 'http://localhost/',
'name' => 'Habbo',
'desc' => 'Best hotel around!',
'email' => 'support@habbo.com',
'in_maint' => false,
'motto' => 'I <3 Habbo!',
'credits' => 5000,
'look_male' => 'hr-831-37.sh-305-62.wa-2007-0.lg-270-79.hd-180-1.ch-215-90',
'look_female' => 'hd-600-1.lg-3057-82.ch-820-1330-1408.sh-3035-1325.hr-515-1396',
'server_ip' => '127.0.0.1',
'server_port' => 30000,
'external_vars' => 'http://localhost/swf/gamedata/external_variables.txt',
'external_texts' => 'http://localhost/swf/gamedata/external_flash_texts.txt',
'product_data' => 'http://localhost/swf/gamedata/productdata.txt',
'furni_data' => 'http://localhost/swf/gamedata/furnidata.xml',
'swf_folder' => 'http://localhost/swf/gordon/PRODUCTION-201512170847-152005991/',
'habbo_swf' => 'Habbo.swf'
),
// invisible recaptcha
'recaptcha' => (object) array(
'active' => false,
'key_private' => '',
'key_site' => ''
),
'social' => (object) array(
'twitter' => '',
'facebook' => '',
'instagram' => ''
)
);
?>
- engine.php
Code:
<?php if (!defined('IN_INDEX')) { die(header('location: ../404')); }
class engine {
private $connected;
public $mysqli;
public function Initiate() {}
public function __construct() {
global $core, $config;
if (!$this->connected) {
$this->mysqli = new mysqli($config->mysql->hostname, $config->mysql->username, $config->mysql->password, $config->mysql->database) or exit($core->systemError('MySQLi Engine', 'MySQLi could not connect to host or database'));
$this->connected = true;
}
}
public function disconnect() {
global $core;
if ($this->connected) {
if ($this->mysqli->close()) {
$this->connected = false;
} else {
$core->systemError('MySQLi Engine', 'MySQLi could not disconnect.');
}
}
}
public function secure($var) {
return $this->mysqli->real_escape_string(stripslashes(htmlspecialchars($var)));
}
public function query($sql) {
return $this->mysqli->query($sql) or die($this->mysqli->error);
}
}
?>
How to make your own theme?
Code:
- enter src/view/views
- create folder
<theme name>
-> admin
-> src
-> css (place your .css files here)
-> js (place your .js files here)
-> img (place your image files here)
-> src
-> css (place your .css files here)
-> js (place your .js files here)
-> img (place your image files here)
-> hotel (needed for client, use the one provided in base theme)
-> hotel.php (used to be client.php, use the one provided in base theme)
-> logout.php (use the one provided in base theme)
- need anything, just grab it from base theme
Credits
- MinCMS -> dimaklt
- RevCMS -> Kryptos
Last edited: