从文件系统加载数据后,哪个模型值得用来调整图像大小并返回客户端?
fs.readFile(process.env.OPENSHIFT_DATA_DIR + request.headers['filename'], function read(err, data) {
var w = request.headers['w']
var h = request.headers['h']
response.writeHead(200)
// CODE TO RESIZE DATA
response.write(data)
response.end()
})
答案 0 :(得分:1)