I\'m new to socket.io and i already have a problem, minor i think. I have installed node.js properly and socket.io too with npm. Then just for testing i cut and paste a sam
You can use mime module as well:
mime
var mime = require('mime') , content_type = mime.lookup(filePath); // handle the request here ... response.setHeader('Content-Type', content_type); response.writeHead(200); response.end(data);