Developing a CMS in node.js

Results 1 to 14 of 14
  1. #1
    Registered Soundwave is offline
    MemberRank
    Jul 2012 Join Date
    The NetherlandsLocation
    7Posts

    idea Developing a CMS in node.js


    RaGEZONE Recommends

    RaGEZONE Recommends

    Greetings,

    First a little bit about myself. I'm a webdeveloper from the Netherlands and I mainly work with the MEAN stack. I've recently started playing around with Habbo retro stuff again (after quite some time) only to find out loads of content management systems are still written in PHP. (the older versions even with deprecated stuff)

    I'd like to start developing one in node.js but I'm a bit lost as to where I can get some info on how to create a working Habbo client 'from scratch'. What I mean by that is that I'd like to be able to create some kind of authentication system myself, and use it's data to login to a Habbo client with said data.

    I mean I could search my way through something like RevCMS but my development environment currently doesn't support the older versions of PHP and I haven't had the time yet to allow for 'backward compatibility'. I'd also like to discuss whether there would be any obvious disadvantages of using node.js instead of the traditional PHP back-end that usually is associated with Habbo that I might be overlooking, which is why I'm also creating this thread.

    Kind regards.

    [Moved from: Retro Habbo Chat to: Coders' Paradise]
    Last edited by Soundwave; 18-11-16 at 12:06 PM.


  2. #2
    Just boot it up! Darky is offline
    True MemberRank
    Oct 2008 Join Date
    Fun landLocation
    93Posts

    Re: Developing a CMS in node.js

    Define why you want to make it on Node.JS?

  3. #3
    Ultimate Member arran565 is offline
    MemberRank
    Aug 2010 Join Date
    ScotlandLocation
    159Posts

    Re: Developing a CMS in node.js

    Personally I would use a full PHP backend.

    I would also recommend not to take inspiration from Rev as its really an over-praised CMS and as I'm sure you will be aware also has a very nooby image to it. There are infact very few Habbo retro CMS' of which I would recommend as they generally either have notable exploits or bad practices in their syntax.
    Alright ;)

  4. #4
    Programmer TimeBomb is online now
    ModeratorRank
    May 2008 Join Date
    United StatesLocation
    1,243Posts

    Re: Developing a CMS in node.js

    Heya Soundwave. I'm not all that familiar with Habbo, but I work professionally with Node.

    There are a few detriments that you'll notice with Node.

    There's a lot more boilerplate. PHP gives you reasonably straight forward technologies. You have the Apache (or nginx) webserver that you don't really have to worry about. You don't have to worry about server-side routing - it just works.
    If you go with Node, you can do everything PHP can do, but you will be setting up your own web server. You'll be setting up whichever build tools you want to go with. There's a non-trivial amount of things to do before you can even start working on the CMS itself.

    Javascript is overly forgiving... to the point where it's unforgiving. It's more lenient, allowing you to do some crazy cool things, while also making it much easier to introduce bugs into your code. Bugs that your code may never even warn you about.

    Javascript & Node's extremely popular right now, and Javascript developers are always innovating. Too much. Keeping up with all the new javascript frameworks and libraries is impossible. Angular 1, Aurelia, Angular 2, Ember, React, Polymer, Backbone, Meteor, Flux, Redux, Vue, Mithril, Express, Koa, Hapi, Grunt, Gulp, Browserify, Webpack, Sails... the language is intensely crowded and hyper-evolving. There are so many different ways to do things - Be careful.

    Really, pick the tools you want to use, don't spend too much time on that. Pick libraries that look like they'll get the job done, that look like they'll be fun to learn, and that have a sizable community.

    Now that you've heard all that, are you sure you want to use Node? Really, you can pick a few libraries and start making something pretty neat. It depends how serious you want to be with it.

    Something to consider is are you sure you want to deviate from the language of the game itself? PHP. PHP isn't evil. That being said, there are many popular, shitty projects in PHP. Horrible, scary, terrible projects, frameworks, libraries, and so on. Heard of Wordpress? Most popular CMS in the world, counts for almost 20% of all websites in the world - written in PHP. And it's coded poorly. Very poorly. In many countries, you can make a living off fixing people's hacked Wordpress sites. (Protip: Use a randomly generated password different from everything else you use. Rename the wp-admin directory. Restrict it to certain IPs if possible. Don't tell WP admins, freelancers need some way to make a quick $300+, right?)

    Now then, have you ever heard of Laravel? Great, great, great PHP framework. Use it. Symfony's pretty cool too. You can write good code in PHP. As good as any other web application in Ruby, Python, Javascript, or Java. Start with a good framework. Just remember to question everything you read and see. Especially if it's an article related to PHP.

    That being said, do use a more modern version of PHP. I don't disagree with you being weary of code that only runs on older PHP versions.

    Habbo communicates with RevCMS using some sort of API, right? At some level, I'm sure. That's just a call over the internet; you can do that with any language. If you really want to pick up Node, go for it. Personally, I'd recommend starting with Express as the web server, and use node's request to make any API calls you need to make. Decide how server/client sided you want your app to be, and roll with it. Angular 1 and React are both quite popular and viable nowadays, but they both have a learning curve.

    In regards to creating your own authentication system, please be careful. Use popular third party libraries as much as possible. Don't implement security yourself. That's how bad things happen. No matter how good you think you are, just use what's already out there. There are dozens of incredibly smart minds, PHDs and what-not, that do security professionally so the rest of us don't have to (because if we tried, we'd get hacked a lot faster than if we followed the experts' recommendations).

    This post may be a bit more than you bargained for haha, but I hope it helps you make a decision. Let us know if you have any other questions :).

  5. #5
    I like turtles Schematic is offline
    True MemberRank
    Aug 2008 Join Date
    FinlandLocation
    705Posts

    Re: Developing a CMS in node.js

    NodeJS is really interesting. I personally started working on NodeJS projects this year, so I have too little knowledge to give any advice as in what to use and what not. But what I can say is that I've actually worked on a couple website projects, one of which we created a content management site for a clothing store which had the administrator ability of adding new items, editing them and deleting. The site was created using React Redux and we used a React Redux Hot Example as a skeleton for the project. I must say that coming from a PHP background to coding stuff entirely on JavaScript was really overwhelming at first, but once I got the hang of things I really started to like it. The thing I also enjoyed very much about React Redux was that whichever change you make into the code, it's being refreshed to the site and it displays all the errors on the screen, without the need to go to the console. This means less spamming F5 to see the change.

    As in for database, we used PostgreSQL with some fancy package for writing the queries, which name I unfortunately have forgotten.

    If I remember correctly, Habbo is a flash game? Or is it a HTML5 game these days? I haven't played that game for at least 10 years. But perhaps consider React Redux as one option.

  6. #6
    Watching from above Negata is offline
    LegendRank
    Apr 2004 Join Date
    FinlandLocation
    5,543Posts

    Re: Developing a CMS in node.js

    It sounds like you guys picked on totally the wrong question there. He's already most comfortable with Node.js stacks and his question was about the Habbo side and creating servers/clients from scratch.
    Bow down before the one you serve.

  7. #7
    ◝(⁰▿⁰)◜Formerly CodeDragon ◝(⁰▿⁰)◜ Taiga is offline
    ModeratorRank
    May 2007 Join Date
    InternetLocation
    2,389Posts

    Re: Developing a CMS in node.js

    The Habbo client is a flash based game, you just need to add a SSO key and server information inside the flash vars if I'm correct. I'm over simplifying. The best thing you could do is to look at existing projects.
    Moderator & Developer
    I CAN NOT HELP YOU WITH YOUR SERVER, USE THE CORRECT HELP SECTION INSTEAD.


    DO NOT PM ME FOR GAME RELATED QUESTIONS, THESE MESSAGES WILL BE IGNORED!

    The Rules | Discord | MMORPG Extra | Contact Me


  8. #8
    :-) s-p-n is offline
    DeveloperRank
    Jun 2007 Join Date
    Next DoorLocation
    2,141Posts

    Re: Developing a CMS in node.js

    The one time I see a thread about node.js, and I have nothing to say because @TimeBomb nailed it. I did write a quick(ish) tutorial on getting started using a basic framework/pattern to help make medium-to-large scale projects in node.js manageable. Well that's my answer to your side-question, as to how to link your habbo client to your server or whatever, @CodeDragon pointed out that you should look at existing projects. I agree.

    Yeah, I guess I just stuck my nose into this thread to give you a link to my tutorial, lol. Great job everyone else who posted!

  9. #9
    Registered Soundwave is offline
    MemberRank
    Jul 2012 Join Date
    The NetherlandsLocation
    7Posts

    Re: Developing a CMS in node.js

    Thanks everyone for taking the time to reply to my post. (especially @TimeBomb) The reason I want to use Node.js is because I've been using Node.js on a daily basis for work and other personal projects. Although I appreciate you guys' enthusiasm and elaborate replies, @Negata is right. My original intent was to get some directions regarding the creation of a Habbo client specifically (as that is something I haven't done before) and to discuss whether Node.js would pose some problems with regard to habbo. I too work professionally with Node.js, so although I really appreciate the elaborate explaination of Node.js in a nutshell and although I agree with almost everything that was said, it wasn't really the goal of this thread.

    To be honest I didn't quite get why my thread was moved here, because all of my questions were aimed towards habbo specifically. So my apologies for the confusion this may have created. I'll take a look at some existing Habbo projects to get a sense of how Habbo clients work, but I was hoping someone could send me a link to a tutorial that explains it well, since most tutorials seem to have been written by 12 year olds.

    Quote Originally Posted by Schematic View Post
    NodeJS is really interesting. I personally started working on NodeJS projects this year, so I have too little knowledge to give any advice as in what to use and what not. But what I can say is that I've actually worked on a couple website projects, one of which we created a content management site for a clothing store which had the administrator ability of adding new items, editing them and deleting. The site was created using React Redux and we used a React Redux Hot Example as a skeleton for the project. I must say that coming from a PHP background to coding stuff entirely on JavaScript was really overwhelming at first, but once I got the hang of things I really started to like it. The thing I also enjoyed very much about React Redux was that whichever change you make into the code, it's being refreshed to the site and it displays all the errors on the screen, without the need to go to the console. This means less spamming F5 to see the change.

    As in for database, we used PostgreSQL with some fancy package for writing the queries, which name I unfortunately have forgotten.

    If I remember correctly, Habbo is a flash game? Or is it a HTML5 game these days? I haven't played that game for at least 10 years. But perhaps consider React Redux as one option.
    I think it's awesome that you know how to use React + Redux, I myself have made a couple of react web applications using MobX. You should check it out, it really uncomplicates how state is managed as opposed to how redux & flux manage state. MobX is the reason I gave React a shot.
    Last edited by Soundwave; 03-12-16 at 07:31 PM.

  10. #10

    Re: Developing a CMS in node.js

    What I can't get is why do you creating it from scratch?

  11. #11
    Registered Soundwave is offline
    MemberRank
    Jul 2012 Join Date
    The NetherlandsLocation
    7Posts

    Re: Developing a CMS in node.js

    Quote Originally Posted by Hedson View Post
    What I can't get is why do you creating it from scratch?
    Like I've said before I don't like the PHP frameworks that are currently out there for Habbo. I don't mean building 'the entire habbo game' from scratch in flash, webgl or html5 canvas and whatnot, but rather building the CMS used around the client from scratch using a platform like Node.js.

  12. #12
    Account Upgraded | Title Enabled! Enough is offline
    True MemberRank
    Oct 2012 Join Date
    227Posts

    Re: Developing a CMS in node.js

    how i can put online a cms site using node? it is compatible with appserver ? or i'm talking bullshit?

  13. #13
    Registered Soundwave is offline
    MemberRank
    Jul 2012 Join Date
    The NetherlandsLocation
    7Posts

    Re: Developing a CMS in node.js

    Quote Originally Posted by Enough View Post
    how i can put online a cms site using node? it is compatible with appserver ? or i'm talking bullshit?
    I'm not all too familiar with appserver but if it runs something like Apache similar to how XAMPP does it, then no. Basically Node.js is the webserver if you're using something like Express within Node. Although you could probably come up with a setup that would allow for both, but that's not what I'd recommend you do.

    I got your private message by the way, I'll look into it but I'm currently a bit busy with work related stuff so I'll get back to you asap.

  14. #14
    Account Upgraded | Title Enabled! Enough is offline
    True MemberRank
    Oct 2012 Join Date
    227Posts

    Re: Developing a CMS in node.js

    Quote Originally Posted by Soundwave View Post
    I'm not all too familiar with appserver but if it runs something like Apache similar to how XAMPP does it, then no. Basically Node.js is the webserver if you're using something like Express within Node. Although you could probably come up with a setup that would allow for both, but that's not what I'd recommend you do.

    I got your private message by the way, I'll look into it but I'm currently a bit busy with work related stuff so I'll get back to you asap.
    Yes, appserv runs an apache similar to xampp. A node server is totally different from that, so I have no idea how to use it hahaha




Advertisement