Skip to content

Instantly share code, notes, and snippets.

@danimajo
Created May 8, 2012 21:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danimajo/2639556 to your computer and use it in GitHub Desktop.
Save danimajo/2639556 to your computer and use it in GitHub Desktop.
static http webserver with node.js and connect
var connect = require('connect');
//Hier den Pfad eingeben,
//indem die statischen (html/js/css) Files liegen.
var HTDOCSPATH = 'C:\\data\\js\\learn'
console.log("serving from dir " + HTDOCSPATH)
connect.createServer(
connect.static(HTDOCSPATH)
).listen(8080);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment