01-25-2016, 09:34 PM
So there are a few things you need to get figured out, then it will be smooth sailing from there:
1. Creating a server
This is not simply make a program listen on a port and send random data. It needs to be threaded so that each thread can listen for a specific client. I also needs to work with javascript's wonky websocket interface. Google it, javascript needs a certain form filled when creating a connection. I don't understand it, I just sort of accepted it.
2. Manipulating html with javascript
In javascript, you can edit the site's html on the client-side. I assume you already understand this, but I will mention it anyway. there is an object (kind of) called document where all the html resides. It has a method "querySelector()" that takes in a string which is the selector. It works exactly like the css selector. It returns an array of type element objects which are basically html objects. these elements have methods/variables such as attributes, style, innerHTML, etc. using an API such as jquery makes things much easier.
3. php & mysql
This is not a must have, but it's good practice. writing data into a mysql database is much more efficient than making files and opening them and reading/writing. PHP is a programming language designed to pre-process a document before sending to recipient. That means each time someone requests a webpage, the respective php script is run in order to output an html document which is then sent to the recipient. This is useful in order to have a sentral database of cards or users(?). You don't need to use PHP (in fact, if you can avoid it, by any means do so), but it's just too easy to install to really worry about it. All you do is simply install a linux package (or if you are using windows, simply an installer).
4. Google
This might sound silly, but it's extremely important. You must know how to use google efficiently. If you are having trouble, learn everything you can about the error before attempting to google it. You might even figure out the solution by trying to understand what the error is trying to say. Also, include error codes and learn what they really mean, they can help a bunch with the problem.
Hopefully you found this wall of text helpful. There is not much else I can tell you that you can't otherwise easily find on the web.
1. Creating a server
This is not simply make a program listen on a port and send random data. It needs to be threaded so that each thread can listen for a specific client. I also needs to work with javascript's wonky websocket interface. Google it, javascript needs a certain form filled when creating a connection. I don't understand it, I just sort of accepted it.
2. Manipulating html with javascript
In javascript, you can edit the site's html on the client-side. I assume you already understand this, but I will mention it anyway. there is an object (kind of) called document where all the html resides. It has a method "querySelector()" that takes in a string which is the selector. It works exactly like the css selector. It returns an array of type element objects which are basically html objects. these elements have methods/variables such as attributes, style, innerHTML, etc. using an API such as jquery makes things much easier.
3. php & mysql
This is not a must have, but it's good practice. writing data into a mysql database is much more efficient than making files and opening them and reading/writing. PHP is a programming language designed to pre-process a document before sending to recipient. That means each time someone requests a webpage, the respective php script is run in order to output an html document which is then sent to the recipient. This is useful in order to have a sentral database of cards or users(?). You don't need to use PHP (in fact, if you can avoid it, by any means do so), but it's just too easy to install to really worry about it. All you do is simply install a linux package (or if you are using windows, simply an installer).
4. Google
This might sound silly, but it's extremely important. You must know how to use google efficiently. If you are having trouble, learn everything you can about the error before attempting to google it. You might even figure out the solution by trying to understand what the error is trying to say. Also, include error codes and learn what they really mean, they can help a bunch with the problem.
Hopefully you found this wall of text helpful. There is not much else I can tell you that you can't otherwise easily find on the web.
<-- The actual Minecraft server host