If cms_settings not present in db

funkystrainz

Member
Oct 12, 2016
106
9
Hello Habbo Community,

After a few weeks of trying out different CMS releases, new and old, I think I am getting close to being able to direct the page forward with session data (using the provided cms variables) & successfully perform queries without syntax errors that have to do with the version of mariadb I am using.

For the complete and proper configuration of my emulator, I think there is a table that is supposed to be included in my db, called cms_settings. I'm wondering if a newly created table would communicate with the emulator, the way one included would.

I'll be using an edited version of PlusEMU on Mac.

I may have to re-create my server_status table, because I still have {online} where there should be a value equal to a number, so creating the cms_settings, will give me an idea of how to do it.

Thanks
 
The index/reg page screenshots in progress:



Tables in database that I need to have queries run in them:
*users
*server_status
 

Blasteh

Lord Farquaad
Apr 3, 2013
1,151
513
I swear, every post I see by you is ranted on and on, you don't tell us directly what your problem is half of the time.

Why don't you just take cms_settings from another emu/database instead of making a thread?
 

Core

Member
Nov 10, 2016
356
138
or just catch the mysql errors, see the missing table columns and bobs your uncle.
You have a working table.

Or if you want to be super genius (IQ 999999) then find the query in the CMS and see what column it uses.
 

funkystrainz

Member
Oct 12, 2016
106
9
I swear, every post I see by you is ranted on and on, you don't tell us directly what your problem is half of the time.

Why don't you just take cms_settings from another emu/database instead of making a thread?
Well would that mean I'd just copy a table from a different SQL? Either way, whether it's in my users or my server_status table, I need for the null content for {username} and {online} to be displayed as a unique value in a session from a post request. The other details were just for a more accurate description of my scenario
 

Core

Member
Nov 10, 2016
356
138
Well would that mean I'd just copy a table from a different SQL? Either way, whether it's in my users or my server_status table, I need for the null content for {username} and {online} to be displayed as a unique value in a session from a post request. The other details were just for a more accurate description of my scenario

That doesn't make sense? I thought the issue was with the server_status table, not the users table?
Are you just trying to get total online users?
If so you can just use

$core->num_rows("SELECT null FROM users WHERE online = '1'");

Or you can use a select count OR just use server_status table..
 

funkystrainz

Member
Oct 12, 2016
106
9
That doesn't make sense? I thought the issue was with the server_status table, not the users table?
Are you just trying to get total online users?
If so you can just use

$core->num_rows("SELECT null FROM users WHERE online = '1'");

Or you can use a select count OR just use server_status table..
I have if($engine->num_rows ("SELECT * FROM users WHERE username = '" . $username . "' LIMIT 1") > 0)

This is what I've been trying to figure out. Even though the script is in place, I can't begin to get session data in post for the me page, from the form on the reg page. So I was more seeking answers for users first, with user count as the second error I was having, unsure of whether or not it was a template error that could be displayed as 0 (from server_status in the db, instead of users).
 

Core

Member
Nov 10, 2016
356
138
I have if($engine->num_rows ("SELECT * FROM users WHERE username = '" . $username . "' LIMIT 1") > 0)

This is what I've been trying to figure out. Even though the script is in place, I can't begin to get session data in post for the me page, from the form on the reg page. So I was more seeking answers for users first, with user count as the second error I was having, unsure of whether or not it was a template error that could be displayed as 0 (from server_status in the db, instead of users).

Yeah it will be stored in the session, not username variable..
$_SESSION["user"]["username"] for revcms.

I'm sure there is also a getInfo function in user class
$user->getInfo(id, column);

which will store data in session for you;
not sure though not used rev in a while
 

funkystrainz

Member
Oct 12, 2016
106
9
Yeah it will be stored in the session, not username variable..
$_SESSION["user"]["username"] for revcms.

I'm sure there is also a getInfo function in user class
$user->getInfo(id, column);

which will store data in session for you;
not sure though not used rev in a while
This was extremely helpful. Not to sound clueless, but how does the database interpret this information? And create a row out of it upon the click of a button? Do I run either of those lines of code as a query?
 

Core

Member
Nov 10, 2016
356
138
This was extremely helpful. Not to sound clueless, but how does the database interpret this information? And create a row out of it upon the submission of an entry? Do I run either of those lines of code as a query?

No they're actually ways of obtaining session data, the second $user->getInfo(..) thing is obtaining data from user table based on the id for first param.
 

funkystrainz

Member
Oct 12, 2016
106
9
No they're actually ways of obtaining session data, the second $user->getInfo(..) thing is obtaining data from user table based on the id for first param.
And so I need for my database to recognize the variable that I have set to the value of a username? I guess the ID & rank would be some of the other values I'd insert. Do I replace the default 'mysql_port' and 'mysql_host' beside the $_CONFIG for my params? Is that also where I could fix hotelName? (Kind of Off topic)
 

funkystrainz

Member
Oct 12, 2016
106
9
Why not stop trying to use a mac? You're clearly having waay to many issues.
The thing is, this, right now, is all just for testing. There are VMs and other operating systems if I dont feel like learning how to run the app on this one. I probably would try to see that this project is successful, before I look to try it on something different. Because this is what I'm going to start with, and I'm somewhat familiar with php nonetheless
 
The thing is, this, right now, is all just for testing. There are VMs and other operating systems if I dont feel like learning how to run the app on this one. I probably would try to see that this project is successful, before I look to try it on something different. Because this is what I'm going to start with, and I'm somewhat familiar with php nonetheless
I'll probably re-think the issue I'm having. I don't think it's anything I can post about, really. It's just that it has to do with the settings of this CMS in particular, so it's not like I could do research on it.
 

Users who are viewing this thread

Top