一个基于七牛云存储 NodeJS SDK 和 jQuery-File-Upload 开发的 Ajax 上传示例程序
一个基于 七牛云存储 NodeJS SDK 开发的 Ajax 上传(jQuery-File-Upload)示例程序。
安装依赖库
npm install express qiniu
获取示例程序源代码:
git clone git://github.com/qiniu/nodejs-ajax-upload-example.git
或者直接下载源码包:https://github.com/qiniu/nodejs-ajax-upload-example/tags
编辑 nodejs-ajax-upload-example/app/server.js
文件, 修改其中配置项 qiniu.conf.ACCESS_KEY
和 qiniu.conf.SECRET_KEY
的值。参考 应用接入:获取Access Key 和 Secret Key
在 nodejs-ajax-upload-example/app
目录下运行命令:node server.js
用浏览器打开 nodejs-ajax-upload-example/public/index.html
进行体验