diff options
Diffstat (limited to 'lib/index.js')
| -rw-r--r-- | lib/index.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/index.js b/lib/index.js index a4e5263..29baa70 100644 --- a/lib/index.js +++ b/lib/index.js @@ -78,6 +78,12 @@ site.init = function(){ }) }) + app.get("/p/get/randomascii", function(req, res){ + db.getRandomAscii().then(function(img){ + res.json(img) + }) + }) + /* shaderblaster / asciiblaster apis */ app.post("/cgi-bin/im/shader/upload", multer_upload.single('qqfile'), function(req, res){ var now = Math.floor(Date.now() / 1000) @@ -112,6 +118,7 @@ site.init = function(){ app.get("/p/:id", function(req, res){ res.sendFile("index.html", {root: './public'}) }) + app.use('/panke/', express.static(path.join(__dirname, '../public'))) app.use('/p/', express.static(path.join(__dirname, '../public'))) } |
