tizen上传文件到服务器同步问题?
我开发一个像shazam的应用程序,但我设法记录,但当我上传音频文件在服务器端使用blob数据也不相同(我还不能播放音频文件)。怎么回事儿?tizen.filesystem.resolve(
'file:///opt/usr/media/test.aac',
function(dir) {
documentsDir = dir;
if (dir != null) {
dir.openStream(
"rw",
function(fs) {
var bt = fs.readBytes(dir.fileSize);
var blob = new Blob(bt, {
type: 'audio/mpeg'
});
var formData = new FormData();
formData.append("__VIEWSTATE", "jjj=");
formData.append("FileUploadControl", blob, "mmm.aac");
formData.append("UploadButton", "Upload");
client.open("post", "/page", true);
client.send(formData);
fs.close();
},
function(e) {
console.log("Error " + e.message);
}
);
}
},
function(e) {
console.log("Error" + e.message);
}, "rw"
);
页:
[1]