-
Fuse Housekeeping [PHP, MySQLi, jQuery]
Fuse Housekeeping
advanced. beautiful. smart. revolutionary.
Introduction
My name is Bill, some of you may remember my first project [Habblux Housekeeping]. Everyone loved it, there was nothing else of its kind publicly released before. I still to this day get asked for the download link and have been asked to update it. I look back at the code and now realize how bad it really is. Security holes, missing features, and to simply put it, [not good enough]. I decided to start this project [Fuse Housekeeping] to help jumpstart new and more advanced future developments in the Habbo Community. Everything I have seen these day have been [nothing new]. All we see are edits and remakes of [the same stuff]. Today I am introducing something that will most defiantly [blow your socks off]. It's still in early development but already has some great features that i have [never seen before].
Features
Code:
- Dynamic page loading [jQuery ajax]
- Template Engine [smarty]
- Responsive [Smartphone / Tablets]
- Permission management [like PhoenixEMU!]
- Session management [see whos really doing what]
- Advanced statistics [hows my hotel REALLY doing]
- Pin code login [extra security!]
more to come...
Code Snippets
Screenshots
FAQ
- When will this be released? / At the current time this project is in development, but keep checking back for a date!
- Is this open-source / available on GitHub? / Yes! Completely open-source. You can find the GitHub here
- What exactly will it do? / Unlike other administration panels that are limited to basic features, Fuse Housekeeping will provide advanced functions that will allow you to control your hotel much more efficiently.
- Can I contribute to the project? / Yes, by all means! Provide as much feedback as possible!
- Will there be a beta? / While there won't be an official beta, you can always find the latest files on GitHub!
- Is this from scratch? / Everything besides the HTML / default template.
this post will be expanded much more soon.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Approved.
Good luck with your project.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Looking good, love the design, good luck :)
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
The design looks familiar for some reason, good luck with this.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
Clawed
The design looks familiar for some reason, good luck with this.
The design can be found here: Dashboard - Metro King
That is the only part of this I didn't make, but that is simply HTML / CSS.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
What happened to your C# forms Housekeeping? Ever finished? Also re-release habblux ;3
is:
Code:
isset($_POST["login"]) && $_POST["login"] == "1")
Not twice the same?
And this too:
Code:
(isset($_POST["user_name"]) && $_POST["user_name"] != NULL)
I would use:
Code:
(!empty($_POST['user_name'])
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
tdid
What happened to your C# forms Housekeeping? Ever finished? Also re-release habblux ;3
is:
Code:
isset($_POST["login"]) && $_POST["login"] == "1")
Not twice the same?
And this too:
Code:
(isset($_POST["user_name"]) && $_POST["user_name"] != NULL)
I would use:
Code:
(!empty($_POST['user_name'])
No, that was never finished I'm sorry =( This project shouldn't take long now that I have all basic functionality working. Adding pages / widgets are very easy and the code is easy to understand. That code is just old habbits :p I really should fix that up :)
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
tdid
Code:
(!empty($_POST['user_name'])
I normally use:
Code:
(isset($_POST['user_name']) && !empty($_POST['user_name']))
But either way works as good.
Also when using MySQLi use prepared statements.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
Clawed
I normally use:
Code:
(isset($_POST['user_name']) && !empty($_POST['user_name']))
But either way works as good.
Also when using MySQLi use prepared statements.
At the moment my quires are pretty basic so I don't really see a need for prepared statements... Could you give me a worth wild example on when I should use them?
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
billsonnn
At the moment my quires are pretty basic so I don't really see a need for prepared statements... Could you give me a worth wild example on when I should use them?
Inserting data, deleting data, updating data, getting data, etc, etc.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
Clawed
Inserting data, deleting data, updating data, getting data, etc, etc.
Well why do all the extra work for prepared statements when I can just do
Code:
if($find_data = Database::db_query("SELECT `id` FROM `users` WHERE `id` = '{$value}' LIMIT 1")) {
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
billsonnn
Well why do all the extra work for prepared statements when I can just do
Code:
if($find_data = Database::db_query("SELECT `id` FROM `users` WHERE `id` = '{$value}' LIMIT 1")) {
Less chance of injection, faster, better, easier, once you get used to them.
Your choice though, i just like seeing people use MySQLi prepared statements, or even PDO prepared statements would be much better!
Anyway good luck!
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
tdid
What happened to your C# forms Housekeeping? Ever finished? Also re-release habblux ;3
is:
Code:
isset($_POST["login"]) && $_POST["login"] == "1")
Not twice the same?
And this too:
Code:
(isset($_POST["user_name"]) && $_POST["user_name"] != NULL)
I would use:
Code:
(!empty($_POST['user_name'])
What you would use:
It can't find user_name in $_POST array -> error.
What I would use:
PHP Code:
<?php
if (isset($_POST['user_name']) && !empty($_POST['user_name']))
(Without filtering of course.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
Clawed
I normally use:
Code:
(isset($_POST['user_name']) && !empty($_POST['user_name']))
But either way works as good.
Also when using MySQLi use prepared statements.
If something is not empty its isset ;) or you can define new variable
$username = $_POST['username'];
if(!empty($username)) { // }
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
tdid
If something is not empty its isset ;) or you can define new variable
$username = $_POST['username'];
if(!empty($username)) { // }
This is not the case. To actually set a variable to the entry 'username' in the POST array, it has to be set, otherwise it will throw an error/notice.
http://i.imgur.com/x4LMUcQ.png
Using isset and empty is probably the best idea, I don't see why you shouldn't use it..
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Loved it. Specially the pin idea, design, etc :D
You have my like!!
-
Quote:
Originally Posted by
Droppy
Loved it. Specially the pin idea, design, etc :D
You have my like!!
Thank you very much :) More information coming soon!
SORRY FOR DOUBLE POSTING
Does anyone have any suggestions for features / security ideas?
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
billsonnn
Thank you very much :) More information coming soon!
SORRY FOR DOUBLE POSTING
Does anyone have any suggestions for features / security ideas?
You could implement charts for users online, server load etc. And implement the housekeeping as a server-dependent API wrapper, like this:
PHP Code:
// This class should perform any server (users, rooms etc) database related actions
class AtomServer extends HabboServer
{
public function __construct($params)
{
$host = $params["host"];
$port = intval($params["port"]);
// TO-DO: Connect to Atom API server
}
public function getOnlineUserCount()
{
// TO-DO: Communicate with the server
return 0;
}
public function getUser($nameOrId)
{
$result = new User();
// TO-DO: Retrieve user attributes from the server or directly from the database
return $result;
}
public function saveUser($user)
{
// This should be called from User::save
// This function should be executed asynchronously.
// TO-DO: Ask the server to save this user attributes or do it directly to the database
return true;
}
public function refreshUser($user, $refresh = null)
{
// This should be called from User::refresh
if($refresh == null)
{
$refresh = array("figure", "coins", "films", "inventory");
}
// TO-DO: Ask the server to refresh the user.
}
public function sendAlert($type, $message, $user = null, $params = null)
{
switch($type)
{
case 0: // Hotel alert
break;
case 1: // Mod message
break;
case 2: // Ban message
break;
case 3: // Hotel alert to user
break;
}
return true;
}
}
About security, IMHO PIN codes does not provide any extra security.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
lab-hotel
You could implement charts for users online.
I did this with google charts, quite easy, i did users online, rooms loaded, credits & pixels :P
Good idea :) +1
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
I love it. Beautiful so far. This is my first time back on ragezone since 2 years ago. I'm glad to be back on, and i'm glad this is the first post i've clicked on since getting on here again. I wish you luck with it and know I plan on using it when it's released!!! Just started my retro anyways and it's quite shit currently because me and my bud Prizm haven't completely decided on a CMS and/or EMU. Oh well. :P Good luck once again.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
lab-hotel
You could implement charts for users online, server load etc. And implement the housekeeping as a server-dependent API wrapper, like this:
PHP Code:
// This class should perform any server (users, rooms etc) database related actions
class AtomServer extends HabboServer
{
public function __construct($params)
{
$host = $params["host"];
$port = intval($params["port"]);
// TO-DO: Connect to Atom API server
}
public function getOnlineUserCount()
{
// TO-DO: Communicate with the server
return 0;
}
public function getUser($nameOrId)
{
$result = new User();
// TO-DO: Retrieve user attributes from the server or directly from the database
return $result;
}
public function saveUser($user)
{
// This should be called from User::save
// This function should be executed asynchronously.
// TO-DO: Ask the server to save this user attributes or do it directly to the database
return true;
}
public function refreshUser($user, $refresh = null)
{
// This should be called from User::refresh
if($refresh == null)
{
$refresh = array("figure", "coins", "films", "inventory");
}
// TO-DO: Ask the server to refresh the user.
}
public function sendAlert($type, $message, $user = null, $params = null)
{
switch($type)
{
case 0: // Hotel alert
break;
case 1: // Mod message
break;
case 2: // Ban message
break;
case 3: // Hotel alert to user
break;
}
return true;
}
}
About security, IMHO PIN codes does not provide any extra security.
Thanks for the tips :) What in your opinion would would be the best idea for security?
I was thinking about maybe implementing some kind of web-socket server to process database stuff and use it to keep everyone up to date across the housekeeping
Updates
Code:
- Pages are grabbed from the database to allow custom permission, staff / public viewing, template selection, as well as including the ability to enable or disable a page
- Pages can now have widgets which are grabbed from the database. You can choose a permission, the template, the size (span max 12), as well as the option to enable or disable it.
- The navigation is now grabbed from the database. Max tree size is 2 (Category -> Page Name). When you set a page id the system will check that pages permission to ensure you have it as well as the enabled or disabled status before passing it into the navigation.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Innovative design, I was expecting dirty code but that shit looks beautifully written. I have the utmost respect for people who know how to properly write php code and tend to it's conventions.
Bravo!
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
Quote:
Originally Posted by
Makarov
Innovative design, I was expecting dirty code but that shit looks beautifully written. I have the utmost respect for people who know how to properly write php code and tend to it's conventions.
Bravo!
THANK YOU! :) All my code is pretty good I think :p
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
I am in very close contact with this project and I can tell you all right now that this is 100 times better than what you are thinking it is. This is revolutionary.
-
Re: Fuse Housekeeping [PHP, MySQLi, jQuery]
I love this housekeeping! It looks sexy.