[ad_1]
Facebook –
GitHub –
Google+ –
LinkedIn –
reddit –
Support –
thenewboston –
Twitter –
Node.js Tutorial for Beginners – 13 – Creating a Basic Server
by
Tags:
Comments
47 responses to “Node.js Tutorial for Beginners – 13 – Creating a Basic Server”
-
You came from heaven to teach me nodeJS .. God Bless you ..
-
I realise that you do not read the comments, but nice stuff. One thing, though, you really need to stop saying "log this out", when you mean to say "write a log message". You are over-subscribing the term 'log out', which really means something entirely different.
-
what should i put in the port no, cause when i put 8888 it shows error??
-
Thank you, Bucky! I can always count on you to make this kind of thing quick, painless, and clear.
-
I get "Process finished with exit code 0" – SERVER DOESN'T RUN , even after I copy pasted the exact code from NewBoston GitHub. Any suggestions ( using Webstorm )?
-
hi,
how can l do if l want to send a javascript page l did change content type : text/javascript , but it didn't nothing. it sent the javascript itself Thanks a lot -
interesting, there is only one 'a user made a request' for me
-
Thanks Bucky. Its the best tutorial for the server.js so far i have watched in youtube
-
where do you write your code?
-
Server Status/Code
200 OK
304 Not Modified
401 Unauthorized
403 Forbidden
404 Not Found
500 Internal Server Error
503 Service Unavailable -
I was the 500th to like 🙂
-
whats the name of this text editor
-
which text editor are you using in this video????
-
The Best Tutorial on Node out there. Thanks, It helped a lot ! It's amazing especially for beginners. You have a great way of teaching things.
-
Woow! This tutorial is awesome! for two days i've been watching all bunch of stuff for hours and i did not understand anything but after this tutorial i know what node.js is, thank you very much
-
The best tutorial i`ve even seen, rlly, thank you
-
THANK YOU FOR UNDOING ALL THE BULLSHIT I HEARD
THANK YOU
sorry -
hey Bucky, thanks for the tutorial. I am also using IntelliJ but for some reason auto-complete does not offer "writeHead" method for the "response" object. It works fine after I hard coded. Additionally, methods writeHead and createServer are underlined with a wavy line. Much appreciate for the response on this matter. Thanks.
-
The cat in GitHub is white, the background is black 🙂
-
Hi,I am using sublime text 3 for this tutorial as it is convenient for me to type and also due to a lot of cool features.I have written the same code for this creating server tutorial.I get the message in the Console as "Server has started" but there on no output in the log and also in the browser I get server not found. :(Please guide me, do I need to download some package?.Thanks in advance!.
-
How do you get that autocomplete on sublime text
-
If every single time you refresh the webpage, onRequest() run twice, so how come "Here is some data" only printed once on web page? Is it suppose to be twice???
-
Why my node.js does not have require() function ! It is saying Unresolved function ! I am using student version, is this the reason ??? Thanks for your video,.
-
How exactly will I be loading the style.css in the handleRequest function? WIll I have to write a seperat function for node to also pull the style.css???
-
I made it.. FINALLY!
DeltaStrikerDoS and
DeltaHavocDDos with DeltaDisease(infecting virus)
darknet hex -
why is how to deal with databases not included in this course!!!
-
Nice video brother… Please guide how to add NODE.JS into bundle.js using browserify as i m getting
ERROR : ReferenceError: require is not defined -
Why is it that when the request.url is printed in the console it shows both the / and the /favicon.ico requests but if you do response.write(request.url), in the browser it only shows the / request?
-
When i run the code it just stops immediately on it's own. no text in the terminal, nothing. It simply stops. Help?
-
Bucky you made it so easy man. Thanks!
-
i am here for agar.io bots do u know how to create agar io bots please create a video then
-
How to create SMPP server using node.js
-
but…i'm confused..
so basically we are creating apache…?
but with javascript?
wot. why? isn't that gonna be like insanely slow? -
response.writeHead(200, ["Context-Type": "text/plain"]);
^
SyntaxError: Unexpected token :Any help that i can get ?
-
Is it best to use node with express for web servers? Or just plain node?
-
Thanks, you were born to teach !
-
epic how these tutorials work for me, unlike many others where they skip details!
-
Aidan?
-
on second run its giving me some error
events.js:141
throw er; // Unhandled 'error' event
^Error: listen EADDRINUSE :::8888
at Object.exports._errnoException (util.js:837:11)
at exports._exceptionWithHostPort (util.js:860:20)
at Server._listen2 (net.js:1231:14)
at listen (net.js:1267:10)
at Server.listen (net.js:1363:5)
at Object.<anonymous> (C:UsersVishalDesktopHTML5Applicationpublic_htmlServer2.js:9:30)
at Module._compile (module.js:434:26)
at Object.Module._extensions..js (module.js:452:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12) -
"favicons" are not these icons on your website, but the icon just before the name of the page on your toolbar 🙂
-
Hi all, I typed the same code. But the server is not connecting to browser. I have also checked the firewall settings, permission is already given to Node.js.
var http = require('http');
function onRequest(request, response){
console.log("A user made a request" + request.url);
response.writeHead(200, {"Content-Type": "text/plain"});
response.write("Here is some data");
response.end();
}http.createServer(onRequest).listen(8888);
console.log("Server is now running…");Any guidance would be rally helpful to me.
-
you had a typo there: you've typed "context-type" instead of "content-type". too much js, probably XD
-
great video so helpful!!
-
Thanks man gr8 tuts
-
Finally, this is what I am waiting for. Tks.
-
This did not work for me, any suggestions?
-
Bucky, MANY THANKS for this set of videos. I'm starting to work with Node.js for some Big Data applications and it helped me a LOT. I've already recommended to all my colleges that will work with me. Thanks again!
Leave a Reply