MinCMS - RevCMS for Arcturus

Results 1 to 12 of 12
  1. #1
    Member dimaklt is offline
    MemberRank
    Dec 2015 Join Date
    GermanyLocation
    51Posts

    config MinCMS - RevCMS for Arcturus


    RaGEZONE Recommends

    RaGEZONE Recommends

    MinCMS is a 2017 RevCMS edit to make it better and faster.
    There's not much RevCMS code left :D

    Github: https://github.com/dimaklt/mincms

    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?

    Spoiler:
    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
    Spoiler:
    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
    Spoiler:
    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?
    Spoiler:
    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 by dimaklt; 5 Days Ago at 08:04 PM.
    Webdesigner & Programmer


  2. #2
    o/ Konquer is offline
    True MemberRank
    Apr 2014 Join Date
    296Posts

    Re: MinCMS - The RevCMS Edit you've been waiting for!

    Not to whine but.. You took away the two reasons people still use Rev

    1. They already know the structure and how to get it up and running easily.
    2. The massive amount of out of the box compatible themes it has.

    The second being the most important imo.

    Adding prepared statements is nice and all, but most of the guys that use rev isn't going to know what that is and how to use it when they add raw php into their views because, hey, that's how rev folks roll.

    On a better note, what other plans do you have for it?
    Lurking around

  3. #3
    Member dimaklt is offline
    MemberRank
    Dec 2015 Join Date
    GermanyLocation
    51Posts

    Re: MinCMS - The RevCMS Edit you've been waiting for!

    Quote Originally Posted by Konquer View Post
    Not to whine but.. You took away the two reasons people still use Rev

    1. They already know the structure and how to get it up and running easily.
    2. The massive amount of out of the box compatible themes it has.

    The second being the most important imo.

    Adding prepared statements is nice and all, but most of the guys that use rev isn't going to know what that is and how to use it when they add raw php into their views because, hey, that's how rev folks roll.

    On a better note, what other plans do you have for it?
    1. It's easy to set up and I will make some themes for it (Priv like theme for example).
    2. Out of the box compatible themes won't really work with Arcturus and RevCMS itself isn't made for the Arcturus database.

    I'd like to keep some basics like {hotelname} and add more (if possible).
    I thought about Bootstrap, but I don't really like it.

    Housekeeping will be the next I work on after I finish user settings and homes in my theme (demo hotel will be available soon).

    Suggestions are accepted :)
    Webdesigner & Programmer

  4. #4
    "(still lacks brains)" NoBrain is online now
    ModeratorRank
    Sep 2011 Join Date
    United KingdomLocation
    2,634Posts

    Re: MinCMS - RevCMS for Arcturus

    Just make an entirely new CMS with unique features rather than beating on the dead horse which is RevCMS.

  5. #5
    o/ Konquer is offline
    True MemberRank
    Apr 2014 Join Date
    296Posts

    Re: MinCMS - The RevCMS Edit you've been waiting for!

    Quote Originally Posted by dimaklt View Post
    I will make some themes for it (Priv like theme for example).
    They don't want a few themes, they want all the themes.

    If you are going to edit rev, make it unique. Add some new features that makes this cms worth using. Right now you're offering prepared statements for hundreds of themes. Not really a trade most users are going to take.
    Lurking around

  6. #6
    Member dimaklt is offline
    MemberRank
    Dec 2015 Join Date
    GermanyLocation
    51Posts

    Re: MinCMS - The RevCMS Edit you've been waiting for!

    Quote Originally Posted by Konquer View Post
    They don't want a few themes, they want all the themes.

    If you are going to edit rev, make it unique. Add some new features that makes this cms worth using. Right now you're offering prepared statements for hundreds of themes. Not really a trade most users are going to take.
    There are already new features and more to come.
    - language system
    - clean code
    - beautiful urls ~ /home/<username> instead of /index.php?url=home&user=<username>
    - more config options
    - Arcturus compatibility
    - MySQLi
    - ..

    Most themes I saw were just image edits of habbos old theme with really bad and unsecure code.

    Honestly.. I don't like PHP that much. But I wanted to recode Rev for years now. I'm still a beginner with PHP and MySQL.
    Last edited by dimaklt; 1 Week Ago at 09:35 AM.
    Webdesigner & Programmer

  7. #7
    Death from above! The General is offline
    The OmegaRank
    Aug 2011 Join Date
    8,719Posts

    Re: MinCMS - RevCMS for Arcturus

    Stop giving him an hard time. Just appreciate that he is actually trying to contribute in some way. He could have also kept this private and nobody would have known.

    He is just trying to learn more about PHP & MySQL (which we should encourage).
    If you are using Arcturus, contact me
    Skype: wesley.jabbo
    Discord: TheGeneral#4898

  8. #8
    Veteran Glaceon is online now
    Alpha MaleRank
    Oct 2012 Join Date
    The NetherlandsLocation
    2,169Posts

    Re: MinCMS - RevCMS for Arcturus

    I was excited when I saw the Arcturus CMS part, it went a bit down when I saw it's based on RevCMS. Nonetheless, good luck with your development! Maybe you should go over to a scratch CMS, but if you don't, I still would encourage you to finish it.
    https://aurora-dev.com/ - https://worldofmrjosh.com

    No matter how much you fall down, you can always reach your destination by standing up again.

  9. #9
    Member dimaklt is offline
    MemberRank
    Dec 2015 Join Date
    GermanyLocation
    51Posts

    Re: MinCMS - RevCMS for Arcturus

    Github: https://github.com/dimaklt/mincms

    - admin (housekeeping) not working (don't know why)

    gif of base theme:



    v0.2 will have many changes
    Webdesigner & Programmer

  10. #10
    "(still lacks brains)" NoBrain is online now
    ModeratorRank
    Sep 2011 Join Date
    United KingdomLocation
    2,634Posts

    Re: MinCMS - RevCMS for Arcturus

    Try to be consistent, avoid global variables and use spaces not tabs. Try to comment your code as well, it's good practice and helps even the most experienced developer. Also try to avoid doing the following using if statements:



    Last edited by NoBrain; 3 Days Ago at 07:34 PM.

  11. #11
    Member dimaklt is offline
    MemberRank
    Dec 2015 Join Date
    GermanyLocation
    51Posts

    Re: MinCMS - RevCMS for Arcturus

    Quote Originally Posted by NoBrain View Post
    Try to be consistent, avoid global variables and use spaces not tabs. Try to comment your code as well, it's good practice and helps even the most experienced developer. Also try to avoid doing the following using if statements:



    How to avoid global variables in functions?

    I don't like the if statements there too.
    Webdesigner & Programmer

  12. #12
    Hardcore Member Pepijntjuh is offline
    MemberRank
    Jun 2016 Join Date
    122Posts

    Re: MinCMS - RevCMS for Arcturus

    Quote Originally Posted by dimaklt View Post
    MinCMS is a 2017 RevCMS edit to make it better and faster.
    There's not much RevCMS code left :D



    Github: https://github.com/dimaklt/mincms

    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?

    Spoiler:
    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
    Spoiler:
    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
    Spoiler:
    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?
    Spoiler:
    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
    Nice work, good code, i'll check it out! ;)
    I have nice themes from Mitchel in HTML & CSS
    Take an look, it will be nice if its on the cms


    Its not spam for other forum, but its nice if u use one of it! ;)
    https://retronet.nl/Thread-REL-Railroad-2-HTML-CSS-SASS
    https://retronet.nl/Thread-Release-D...-CSS-SASS-SCSS
    https://retronet.nl/Thread-REL-Blaze...-HTML-CSS-SASS


    UPDATE
    I have fixed that its generate users for the Plus db now
    Last edited by Quackster; 6 Hours Ago at 06:52 PM. Reason: This isnt the place to discuss whatever emulator is better.




Advertisement