I want to load a local jquery file into my node js chat.I application I searched a lot, but I can not find a suitable solution.
<!doctype html> <html> <head> <title>Socketio</title> </head> <body> <script src="/socket.io/jquery.min.js"></script> <script src="/socket.io/socket.io.js"></script> </body> </html>
I just copy the jquery.js file to the socket.io folder. The socket.io.js file loads correctly, but the jquery didnt file. Please help me. Here is my index.js file
var app = require('express')(); var server = require('http').Server(app); var io = require('socket.io')(server); app.get('/', function(req, res){ res.sendFile(__dirname + '/index.html'); }); server.listen(3000, function(){ console.log('listening on *:3000'); });
source share