Tag Archives | Socket.io

How to run a https website with Nodejs, express and socket.io

Step 1: generate RSA key Use command line: (on Windows we can use Cygwin) Result: Step 2: create file csr.pem Result: Step 3: create SSL certificate file Result: Note: this is in practice, in production you must buy one certificate or use free SSL Step 4: continue with Nodejs app here an example app: app.js […]

Read full story Comments { 1 }

Example chat application using Nodejs + Socket.io

With Nodejs, we can create real-time application like chat-room. We can use Socket.io, WS or Websocket. Today, we introduce a simple chat application with Nodejs + Socket.io Application structure: File: package.json File: index.html File: app.js Run: node app.js Go to website: http://localhost:443/ Next tutorial: Example chat application using Nodejs + Websocket

Read full story Comments { 1 }

How to Install socket.io on Node.js on Windows 7

Windows 7 32bit Step 1: install Node.js Download the Windows Installer: Eg:http://nodejs.org/dist/v0.10.5/node-v0.10.5-x86.msi You can find more available version of node js here: https://nodejs.org/en/download/releases/ You install Node.js … Step 2: run CMD as Administrator change dir to your application folder (ex: D:\AppServ\www\chat) Step 3: install Socket.io Use command: npm install socket.io@0.8.4 Result: D:\AppServ\www\chat>npm install socket.io@0.8.4 npm […]

Read full story Comments { 0 }